vite-plugin-conditional-compile
JSON →A Vite plugin that implements conditional compilation using preprocessor-like directives (#if, #elif, #else, #endif), similar to C/C++ #ifdef. It allows selective inclusion/exclusion of code blocks based on environment variables, custom variables, and logical expressions. Current stable version is 1.4.5, released on an irregular cadence. Key differentiators: supports JSX, Vue templates, and arbitrary file types; integrates with Vite's loadEnv; enables flexible condition syntax with logical operators and nested expressions. Requires Vite ^4.5.0 as a peer dependency. Ships TypeScript types.
Traffic · last 30 days ↓67% vs prev 7d
total hits 11
actors 3 distinct systems
last hit 6d ago human
top countries 🇺🇸 United States · 🇨🇦 Canada · 🇫🇷 France · 🇪🇸 Spain