vite-plugin-treat-umd-as-commonjs
JSON →Vite plugin that resolves edge cases when using RequireJS/AMD in the browser by injecting `var define = false;` into UMD modules, preventing RequireJS from hijacking them. This addresses a specific issue where Vite's UMD-to-CommonJS conversion breaks in a browser RequireJS environment (vitejs/vite#5900). Current version 0.1.4, ships TypeScript types, requires Vite as peer dependency. Use this when you need to serve UMD modules via Vite but the page also includes RequireJS (e.g., legacy dependencies). The plugin is lightweight and scoped to this single concern.
Traffic · last 30 days ↑0% vs prev 7d
total hits 10
actors 3 distinct systems
last hit 6d ago human
top countries 🇺🇸 United States · 🇨🇦 Canada