Browserify transform to inline and precompile rincewind templates
JavaScript HTML
Fetching latest commit…
Cannot retrieve the latest commit at this time.
Permalink
Failed to load latest commit information.
test
.gitignore
README.md
index.js
package.json

README.md

rincewind-precompile-transform

Browserify transform to inline and precompile rincewind templates.

Finds all rincewind calls in source and loads the view and any subviews and replaces with a parsed JSON precompiled version.

NPM

Example

// entry.js
var View = require('rincewind')

var master = View(__dirname + '/master.html')

var views = {
  'index': View(__dirname + '/index.html'),
  'page': View(__dirname + '/page.html')
}
$ browserify entry.js -t rincewind-precompile-transform > output.js
// output.js
var View = require('rincewind')

var master = View({...compiled view...})

var views = {
  'index': View({...compiled view...}),
  'page': View({...compiled view...})
}