vite-plugin-magic-preloader
JSON →Vite plugin that enables Webpack-style magic comments (/* vitePrefetch: true */, /* vitePreload: true */) for dynamic imports, allowing fine-grained control over preloading and prefetching of resources. Current stable version: 1.2.1. Released: December 2021, with recent updates adding attrs support (functions accepted in v1.1.1). Only works within import() statements; does not affect static imports. Key differentiator: provides magic comments missing from Rollup/Vite, targeting Vue and React lazy-loaded routes. Ships TypeScript types. Requires Vite >= 2.0.0 as peer dependency.
Traffic · last 30 days stale · no recent hits
total hits 23
actors 6 distinct systems
last hit 18d ago ByteDance
top countries 🇺🇸 United States · 🇸🇬 Singapore · VN · 🇫🇷 France · BD
Resources
API endpoints
compatibility /v1/registry/vite-plugin-magic-preloader/compatibility