gulp-jade-inheritance
Rebuild a jade file with other files that have extended or included those file
Inspired by jade-inheritance
Install
npm install gulp-jade-inheritance --save-dev
Usage
gulpfile.js
var jadeInheritance = ;var jade = ; gulp;
In this example jade compile example.jade
and all other files that have been extended or included example.jade
. The plugin searches for those dependencies in the basedir
directory.
Only process changed files
You can use gulp-jade-inheritance
with gulp-changed
and gulp-cached
to only process the files that have changed. This also prevent partials from being processed separately by marking them with an underscore before their name.
'use strict';var gulp = ;var jadeInheritance = ;var jade = ;var changed = ;var cached = ;var gulpif = ;var filter = ; gulp;gulp;gulp;
If you want to prevent partials from being processed, mark them with an underscore before their name or their parent folder's name. Example structure:
/app/index.jade
/app/_header.jade
/app/_partials/article.jade
/dist/
To install all that's need for it:
npm install gulp-jade-inheritance gulp-jade gulp-changed gulp-cached gulp-
jade >= 1.11
if your using jade 1.11 add "jade": "^1.11.0"
to your package.json
to overwrite the jade-inheritance version. Issue