/** * IIFE entry (dist/tyrekick.js, global `Tyrekick`). Re-exports the public API and * auto-initialises from data-* attributes on its own * * For framework/async loaders (next/script, dynamic import, bundlers) where * `document.currentScript` is null, set a global instead: * * */ export { init, destroy } from "./index"; import { init } from "./index"; import type { Position, Transport, TyrekickConfig } from "./types"; // Must be read synchronously at eval time — currentScript is null by the time // DOMContentLoaded fires, and also null whenever the script is injected // asynchronously (next/script, dynamic import, bundlers). Kept for the classic // synchronous