@nx-js/style-middleware

An NX middleware, responsible for dynamic styling.

Stats

stars 🌟issues ⚠️updated 🛠created 🐣size 🏋️‍♀️
00Feb 10, 2017Dec 31, 2016Minified + gzip package size for @nx-js/style-middleware in KB

Readme

The style middleware

The style middleware is responsible for dynamic styling.

  • name: style
  • middleware dependencies: attributes
  • all middleware dependencies: observe, attributes
  • processes: element nodes
  • throws on: nothing
  • use as: component or content middleware
  • docs

Installation

npm install @nx-js/style-middleware

Usage

const component = require('@nx-js/core')
const observe = require('@nx-js/observe-middleware')
const attributes = require('@nx-js/attributes-middleware')
const style = require('@nx-js/style-middleware')

component()
  .useOnContent(observe)
  .useOnContent(attributes)
  .useOnContent(style)
  .register('stylish-comp')
<stylish-comp>
  <div @class="{big: true, outlined: shouldOutline}"></div>
</stylish-comp>

If you find any bugs or have a feature request, please open an issue on github!

The npm package download data comes from npm's download counts api and package details come from npms.io.