Layers@knitui/map
Fill Extrusion Layer
FillExtrusionLayer renders polygons as extruded 3D volumes. fillExtrusionHeight (and optional fillExtrusionBase) drive each shape's vertical extent — typically from a data-driven height property — and are best viewed with a tilted Camera (pitch/bearing). Shading responds to the map's <Light>. It must live inside a source and reference it via source.
WebiOSAndroidnative split14 own props3 examples
import { FillExtrusionLayer } from "@knitui/map";Playground
Loading playground…
<FillExtrusionLayer />Examples
Buildings3 D
3D buildings extruded by each footprint's height property, viewed at a tilt.
Loading example…
Colored By Height
Height-driven color ramp: shorter buildings are light, taller ones deepen to blue.
Loading example…
With Light
The same extrusions paired with a <Light>: a warm, low-anchored directional light shifts how the building faces are shaded.
Loading example…
Props
| Prop | Type | Default | Description |
|---|---|---|---|
afterId | string | undefined | — | |
beforeId | string | undefined | — | |
filter | FilterSpecification | undefined | — | |
id | string | undefined | — | |
layerIndex | number | undefined | — | |
layout | Record<string, unknown> | undefined | — | |
maxzoom | number | undefined | — | |
minzoom | number | undefined | — | |
paint | Record<string, unknown> | undefined | — | |
source | string | undefined | — | |
source-layer | string | undefined | — | |
sourceLayer | string | undefined | — | |
style | FillExtrusionLayerStyle | undefined | — | |
testID | string | undefined | — |