Skip to content

Rendering engine for Mustache templates powered by Hogan.js.

License

Notifications You must be signed in to change notification settings

sailjs/render-hogan

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

9 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

Sail / Render-Hogan

This module provides an engine for rendering Mustache templates in Sail.js applications. Internally, Hogan.js is used to render templates.

Install

component
$ component install sailjs/render-hogan
volo
$ volo add sailjs/render-hogan

Usage

Register engine with render to process Mustache templates:

render.engine('text/x-mustache-template', hogan());

Compatibility

AMD

Hogan.js does not ship with AMD support. Be sure to include a shim, so that hogan it is usable within an AMD loader.

require.config({
  shim: {
    'hogan': {
      exports: 'Hogan'
    }
  }
});
component

This module uses the AMD format. To include in component builds, use component-amd:

component build -u component-amd

Tests

To run tests in a browser, execute the Make target for the desired browser:

$ make test-chrome
$ make test-firefox
$ make test-safari

Headless tests can be executed directly from a terminal:

$ make test-phantomjs

Credits

License

The MIT License

Copyright (c) 2013 Jared Hanson <http://jaredhanson.net/>

About

Rendering engine for Mustache templates powered by Hogan.js.

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published