fallbackswigloader

1.0.0 • Public • Published

Fallback Swig Loader

A template loader for SWIG that uses a list of folders and falls down the chain of them until a file is found.

Usage:

var fallbackswigloader = require("../fallbackswigloader");
swig.setDefaults({ loader: fallbackswigloader([
	path.join(__dirname, "dir1"),
	path.join(__dirname, "dir2"),
	path.join(__dirname, "dir3")
])});

With path being the built-in path moudle.

That's it really.

I might write tests someday

Readme

Keywords

none

Package Sidebar

Install

npm i fallbackswigloader

Weekly Downloads

2

Version

1.0.0

License

none

Last publish

Collaborators

  • kennydude