- Docs
- Help
- Styles missing
Docs for VelinStyle 1.3.x · verified against 1.3.0
Styles are missing 1.3.0
Check the CSS link, production trimming, and dynamic classes in the rendered page. Deutsch
Problem
Layout looks unstyled, or only dynamically added classes vanish after production.
First check
Run the general diagnostic from the project directory first.
npx @birdapi/velinstyle doctor
Deeper check
npx @birdapi/velinstyle check ./index.html --profile docs
npx @birdapi/velinstyle production . --safelist .my-dynamic-class
Quick check
- Run commands from the intended project directory.
- Use only documented profiles and flags.
- Check again after every change.
The stylesheet is not linked
Cause: The document never loads dist/velinstyle.min.css (or a production CSS sibling).
- Solution 1: Add a correct relative/absolute
<link> to dist/velinstyle.min.css. - Solution 2: Load matching theme CSS from
dist/themes/ when themes are used. - Solution 3: Verify with Network that the CSS returns 200, then re-run doctor.
Verify againnpx @birdapi/velinstyle doctor
npx @birdapi/velinstyle check ./index.html --profile docs
Production removed a dynamic class
Cause: A class only present at runtime was purged from the production CSS.
- Solution 1: Rebuild with
npx @birdapi/velinstyle production . --safelist .my-dynamic-class. - Solution 2: Keep the safelist minimal—only classes that never appear in static HTML.
- Solution 3: Point the page at
dist/velin-production/ and confirm the class survives.
Verify againnpx @birdapi/velinstyle doctor
npx @birdapi/velinstyle check ./index.html --profile docs