Files
MagicMirror/js/suncalc-global.mjs
Kristjan ESPERANTO dbc7a574eb chore: update dependencies and adjust import path for SunCalc (#4189)
With SunCalc v2 we have to point the browser vendor mapping to the new
CJS bundle.
2026-06-21 14:43:18 +02:00

9 lines
313 B
JavaScript

/*
* Bridge for SunCalc v2 (ESM-only entry):
* default modules still expect a global `SunCalc` from getScripts()/vendor loading.
* Keep this as a tiny compatibility shim until the module loader is fully ESM-first.
*/
import * as SunCalc from "../node_modules/suncalc/index.js";
globalThis.SunCalc = SunCalc;