(coords: [number, number][])
| 18 | } |
| 19 | |
| 20 | function buildCacheKey(coords: [number, number][]) { |
| 21 | return JSON.stringify(coords.map(([lon, lat]) => [Number(lon.toFixed(5)), Number(lat.toFixed(5))])); |
| 22 | } |
| 23 | |
| 24 | function getCachedTimeseries(key: string, allowStale = false) { |
| 25 | const cached = timeseriesCache.get(key); |