5.12.2 • Published 7 years ago

static-engine-render v5.12.2

Weekly downloads
43
License
MIT
Repository
github
Last release
7 years ago

static-engine-render

Dependency Status devDependency Status js-standard-style

This is a plugin for static-engine. It renders and saves a file using a provided render function for each object in the collection. Pass it first a route, the file to save. It will interpolate properties from each object into the string provided. Second pass it a function to use for rendering. For each object in the collection it is passed first the object and then a callback function. The renderer may use the callback or optionally return a promise.

var engine = require('static-engine')
var render = require('static-engine-render')
var pluginA = require('plugin-a')
var renderer = function (page, done) {
  // some templating
  done(err, result)
}

engine([
  pluginA,
  render('./your-route/:var/index.html', renderer)
])
5.12.2

7 years ago

5.12.1

7 years ago

5.12.0

7 years ago

5.11.5

8 years ago

5.11.4

8 years ago

5.11.3

8 years ago

5.11.2

8 years ago

5.11.1

8 years ago

5.11.0

8 years ago

5.10.0

8 years ago

5.9.0

9 years ago

5.8.0

9 years ago

5.7.0

9 years ago

5.6.1

9 years ago

5.6.0

9 years ago

5.5.0

9 years ago

5.4.1

9 years ago

5.4.0

9 years ago

5.3.0

9 years ago

5.2.2

9 years ago

5.2.1

9 years ago

5.2.0

9 years ago

5.1.0

9 years ago

5.0.1

9 years ago

5.0.0

9 years ago

4.3.0

9 years ago

4.2.1

9 years ago

4.2.0

9 years ago

4.1.0

9 years ago

4.0.0

9 years ago

3.1.0

9 years ago

3.0.0

9 years ago

2.2.0

9 years ago

2.1.1

9 years ago

2.1.0

9 years ago

2.0.0

9 years ago

1.2.0

9 years ago

1.1.0

9 years ago

1.0.1

9 years ago

1.0.0

9 years ago