Naughty Programmer's Madness
Share your code. npm Orgs help your team discover, share, and reuse code. Create a free org »

This package has been deprecated

Author message:

jade-filters will be unpublished soon, please use pug-filters

jade-filters

1.1.0 • Public • Published

jade-filters

Code for processing filters in jade templates

Build Status Dependency Status NPM version

Installation

npm install jade-filters

Usage

var filters = require('jade-filters');

filters.handleFilters(ast, filters)

Renders all Filter nodes in a Jade AST (ast), using user-specified filters (filters) or a JSTransformer.

filters.runFilter(name, str[, options[, currentDirectory]])

Invokes filter through jstransformer.

This is internally used in filters.handleFilters, and is a lower-level interface exclusively for invoking JSTransformer-based filters.

name represents the name of the JSTransformer.

str represents the string to render.

currentDirectory is used when attempting to require the transformer module.

options may contain the following properties:

  • minify (boolean): whether or not to attempt minifying the result from the transformer. If minification fails, the original result is returned.

License

MIT

Keywords

install

npm i jade-filters

Downloadsweekly downloads

51

version

1.1.0

license

MIT

homepage

github.com

repository

Gitgithub

last publish

collaborators

  • avatar
  • avatar
  • avatar
  • avatar
  • avatar
Report a vulnerability