Skip to content

Support jade.compileFile #12

@ForbesLindesay

Description

@ForbesLindesay

I'm planning to land a new API in jade (pugjs/pug#1596) that I think could be really awesome for browserify. It would allow us to support something like:

var jade = require('jade');
var template = jade.compileFile(__dirname + "/template.jade");

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

The benefit of this would be that it is much closer to the sort of code that you'd expect to see on the server side. It would even allow many modules to share client side and server side code while doing jade rendering.

Would you consider supporting this?

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions