MapGraticule
Renders graticule lines as an SVG <path> layer
Props
| Parameter | Type | Default | Description |
|---|---|---|---|
config? | GraticuleConfig | — | See usage below |
Use native SVG presentation attrs like stroke directly on MapGraticule lines.
Wrap graticule lines in MapSphere to keep them above the sphere background and below the sphere border.
Config
Use config to call graticule generator methods before rendering
ts
{
[methodName: string]: Arg | Arg[]
}- Single non-array value:
Arg | [Arg]- pass directly or wrap with an array - Single array value:
[Arg]- must be wrapped with an array - Multiple values:
[Arg1, Arg2, ...]
See available methods in d3-geo graticule docs
Usage
vue
<template>
<MapBase>
<MapSphere fill="#fff" stroke="#cbd5e1">
<MapFeatures :data="mapData" fill="#f1f5f9" />
<MapGraticule
stroke="#94a3b8"
:config="{
step: [[15, 15]],
precision: 2.5,
}"
/>
</MapSphere>
</MapBase>
</template>