css-2

CSS module loader: apply namespaces and expand URLs.

Note: you may want to look at importing CSS modules from sjs-3 apps.

.Request - upon serving requests

This app does the following:

  • namespace all class selectors (.div may become .NF34E57E0-div)
  • namespace all font names (MyFont becomes NF34E57E0-MyFont)
  • namespace all animation names (bounce becomes NF34E57E0-bounce)
  • rewrite url() references
    • add caching
    • fully expand path For example, url(image.jpg) may become /style.css/image.jpg?o1-cache=01a8d7357ec5493f965d6e3b8f56745c1dd3c3d095)

.CssModule - upon being imported

See the .CssModule interface specification.

Implemented OS Interfaces

.CssModule
.Request
Subscribe to our newsletter!