tileKeyPartsfunction
The level, column and row a tile key ends in, or undefined for a key that does not end in three numbers.
Import it
import { tileKeyParts } from "@johnmorrisdotca/chikyu-earth/door";
Definition
function tileKeyParts(key: string): TileId | undefined
Parameters
| Name | Type | Description |
|---|---|---|
key | string | The tile's key. |
Returns
TileId | undefined
Where the tile is in the pyramid, or undefined for a key that does not end in three numbers.
Examples
import { tileKeyParts } from "@johnmorrisdotca/chikyu-earth/door";
console.log(tileKeyParts("day/3/12/5"));{ level: 3, col: 12, row: 5 }What it prints (run when this page was built)