js-kyle / mincer

Sprockets inspired web assets compiler for Node.js
http://js-kyle.github.io/mincer/
MIT License
628 stars 84 forks source link

Jade deprecation warning is so damn ugly in my log #213

Closed naxmefy closed 8 years ago

naxmefy commented 8 years ago

this is the problem: https://github.com/nodeca/mincer/blob/master/lib/mincer/engines/jade_engine.js#L82

if this option is set - jade will prompt the deprecation warning T_T

it is possible to change this:

    var compile = Jade.compileClient || Jade.compile;

    this.data = compile(this.data, _.assign({}, options, {
      client:   true, // needed only for Jade < v1.0.0
      filename: context.pathname
    })).toString();
    return;

to this:

    var compile = Jade.compileClient || Jade.compile;

    var jadeOpts = {};
    opts.filename = context.pathname;
    if(Jade.compile) opts.client = true; // needed only for Jade < v1.0.0

    this.data = compile(this.data, _.assign({}, options, jadeOpts)).toString();
    return;
naxmefy commented 8 years ago

nevermind this issue...

the problem is at connect-mincer ... it references an old version of mincer

Solved with a fork...