0.0.5 • Published 5 years ago

pug-stylus v0.0.5

Weekly downloads
11
License
MIT
Repository
github
Last release
5 years ago

Setup filter

Install dependencies

npm install stylus

Set as pug filter

const pug = require('pug');
pug.filters.stylus = require('pug-stylus')();

Set filename for stylus when render

pug.filters.stylus = require('pug-stylus')(function (options, args) {
  options.filename = args.filename;
});

Use filter

:stylus
  body
    color red

Output:

body{color:red}

Pretty render.

:stylus(compress=false)
  body
    color red

Output:

body {
  color: red;
}

Render with style tag.

:stylus(wrap=true)
  body
    color red

Output:

<style>body{color:red}</style>
0.0.5

5 years ago

0.0.4

5 years ago

0.0.3

5 years ago

0.0.2

5 years ago

0.0.1

5 years ago

1.0.1

6 years ago

1.0.0

6 years ago