# gulp-nunjucks-inheritance

> Recompile only changed Nunjucks files and their dependencies (extended, included or imported)

Latest version **1.0.1** (published 2019-04-08) · MIT license · 0 weekly downloads

## Install

```sh
npm install gulp-nunjucks-inheritance
pnpm add gulp-nunjucks-inheritance
yarn add gulp-nunjucks-inheritance
bun add gulp-nunjucks-inheritance
```

## Health

**Score 15/100 (F)** — status: abandoned.

Positive: no vulnerabilities.

Warnings: low downloads; no types; no esm support.

Negative: abandoned; low maintenance score.

## Facts

| | |
|---|---|
| Version | 1.0.1 |
| Published | 2019-04-08 |
| First published | 2019-04-08 |
| Weekly downloads | 0 |
| License | MIT |
| TypeScript types | none |
| Module format | CommonJS |
| Dependencies | 4 |
| Unpacked size | 29 KB |
| Known vulnerabilities | 0 |
| Install scripts | no |
| GitHub stars | 0 |
| Author | Antoine COMBES |
| Maintainers | antoine.combes |
| Keywords | gulpplugin, nunjucks, nunjucks-graph, gulp-cached |

## Links

- npm: https://www.npmjs.com/package/gulp-nunjucks-inheritance
- Repository: https://github.com/Acombes/gulp-nunjucks-inheritance
- Homepage: https://github.com/Acombes/gulp-nunjucks-inheritance#readme
- Issues: https://github.com/Acombes/gulp-nunjucks-inheritance/issues
- npm.io page: https://npm.io/package/gulp-nunjucks-inheritance

## Dependencies (4)

- [should](https://npm.io/package/should.md) ^13.2.3
- [vinyl-fs](https://npm.io/package/vinyl-fs.md) ^3.0.3
- [event-stream](https://npm.io/package/event-stream.md) ^4.0.1
- [nunjucks-graph](https://npm.io/package/nunjucks-graph.md) ^1.0.2

## Alternatives

- [memory-cache](https://npm.io/package/memory-cache.md) — 795.0K weekly downloads
- [@httptoolkit/proxy-agent](https://npm.io/package/@httptoolkit/proxy-agent.md) — 11.2K weekly downloads
- [express-cache-controller](https://npm.io/package/express-cache-controller.md) — 5.3K weekly downloads
- [http-cache-middleware](https://npm.io/package/http-cache-middleware.md) — 4.5K weekly downloads
- [cache2](https://npm.io/package/cache2.md) — 1.5K weekly downloads

## Recent versions

- 1.0.1 (latest) — 2019-04-08
- 1.0.0 — 2019-04-08

## README

# gulp-nunjucks-inheritance
Recompile only changed Nunjucks files and their dependencies (included, extended, or imported).

## Installation

```bash
npm i gulp-nunjucks-inheritance
```

## Usage

Suggest to work with [gulp-nunjucks](https://www.npmjs.com/package/gulp-nunjucks) and [gulp-cached](https://www.npmjs.com/package/gulp-cached).

```javascript
var gulp = require('gulp');
var nunjucksInheritance = require('gulp-nunjucks-inheritance');
var nunjucks = require('nunjucks');
var cached = require('gulp-cached');
 
gulp.task('html', function() {
    return gulp.src('src/nunjucks/**/*.njk')
 
      //filter out unchanged NJK files
      .pipe(cached('njk'))
 
      //find files that use the files that have changed 
      .pipe(nunjucksInheritance({base: 'src/nunjucks'}))
 
      //process scss files 
      .pipe(nunjucks.compile())
 
      //save all the files 
      .pipe(gulp.dest('dist'));
});
```

---
_Source: https://npm.io/package/gulp-nunjucks-inheritance · Machine-readable twin of the npm.io package page. Health data is recomputed on every publish._
