Norvell's Public Machinations
    Share your code. npm Orgs help your team discover, share, and reuse code. Create a free org »

    simple-jadeifypublic

    This package has been deprecated

    Author message:

    simple-jadeify has been renamed to jadeify; use that package instead.

    A Simple Browserify Transform for Jade

    Simple Jadeify lets you use Jade templates with browserify in the simplest way possible:

    var template = require("./template.jade");
     
    document.getElementById("my-thing").innerHTML = template({
        localVar: "value",
        anotherOne: "another value"
    });

    Setup

    Dead simple. When creating your browserify bundle, just add this line:

    bundle.transform(require("simple-jadeify"));

    or if you are a command line cowboy, something along the lines of

    browserify -t simple-jadeify entry.js -bundle.js

    Note that this project peer-depends on Jade and each template will do require("jade/runtime"), so everything will just work: there's no need to add any Jade-related stuff to your bundle manually.

    So yeah, now requireing any .jade files will give you back a template function. Have fun!

    Keywords

    none

    install

    npm i simple-jadeify

    Downloadsweekly downloads

    21

    version

    2.1.0

    license

    none

    repository

    githubgithub

    last publish

    collaborators

    • avatar