Imports Chart.js, D3.js, and Papa Parse as ES modules and registers them on globalThis.
Dashboard modules access these libraries via (globalThis as unknown as { Chart: { new(ctx: HTMLCanvasElement | CanvasRenderingContext2D | null, config: Record<string, unknown>): unknown; register(...items: unknown[]): void } }).Chart, (globalThis as unknown as { d3: typeof import('d3') }).d3, and (globalThis as unknown as { Papa: { parse(input: string, config?: Record<string, unknown>): { data: string[][] } } }).Papa. ES module side-effect imports (import 'chart.js/auto') do NOT set globals, so this module must be imported before any dashboard module to ensure the globals are available at module initialization time (when the importing module is first executed).
Security
No inline scripts โ all library loading is programmatic via Vite bundling
Description
Imports Chart.js, D3.js, and Papa Parse as ES modules and registers them on globalThis.
Dashboard modules access these libraries via
(globalThis as unknown as { Chart: { new(ctx: HTMLCanvasElement | CanvasRenderingContext2D | null, config: Record<string, unknown>): unknown; register(...items: unknown[]): void } }).Chart,(globalThis as unknown as { d3: typeof import('d3') }).d3, and(globalThis as unknown as { Papa: { parse(input: string, config?: Record<string, unknown>): { data: string[][] } } }).Papa. ES module side-effect imports (import 'chart.js/auto') do NOT set globals, so this module must be imported before any dashboard module to ensure the globals are available at module initialization time (when the importing module is first executed).Security
No inline scripts โ all library loading is programmatic via Vite bundling