Reference · Markers on the globe
GroupInfotype
One group of markers: its name, how many it holds and whether it is shown.
Import it
import type { GroupInfo } from "@johnmorrisdotca/chikyu-earth/markers";
Definition
interface GroupInfo {
name: string;
count: number;
visible: boolean;
}
Members
| Name | Type | Description |
|---|---|---|
name | string | |
count | number | |
visible | boolean |
Examples
import type { GroupInfo } from "@johnmorrisdotca/chikyu-earth/markers";
const show = (groups: GroupInfo[]): string => groups.map((group) => `${group.name}: ${group.count}${group.visible ? "" : " (hidden)"}`).join(", ");
console.log(show([{ name: "Cities", count: 3, visible: true }]));Cities: 3What it prints (run when this page was built)