Skip to content

mergeBasemap

mergeBasemap(base, projected): EmitResult

Defined in: packages/core/src/emitter/basemap.ts:74

Merge a projected document over a base style.

ParameterType
baseunknown
projectedEmitResult

EmitResult

The document wins on every conflict. It is the thing being authored; the basemap is the substrate. But a silent win is a debugging problem — an author who unknowingly shadows a basemap source gets a map that renders wrong with no explanation — so every collision warns.

Layer order across the seam is the substantive decision here. Document layers append after the base’s by default, which is what “draw my data on top of the map” means. A before naming a base layer inserts at that position instead, which is how a layer gets slotted underneath labels — the common reason to reach for it at all.