This site is built with Viewi itself. It is experimental and still in development. If you see any bugs please do not hesitate and open an issue or DM me on Twitter.

Css Bundle

Viewi has a helper component that allows you to include your css file(s). It has the following syntax:

<CssBundle link="/css/main.css" />

But if you need to include more than one file you can use:

<CssBundle links="{['/css/main.css', '/css/admin.css', '/css/icons.css']}" />

Additionally Css Bundle supports a couple more features:

<CssBundle 
links="{['/css/main.css', '/css/admin.css', '/css/icons.css']}"
minify="true"
shakeTree="true"
combine="true"
inline="true"
/>

Where:

  • minify - true if you want your css file to be minified.
  • shakeTree - true if you want to remove unused rules based on html templates.
  • combine - true if you want all of your files to be concatenated and included as a single file.
  • inline - true if you want your css to be included as internal inline css.