handlebars-resolve

0.4.3 • Public • Published

Handlebars Resolve

Build Status

Sometimes you wanna make super cool Handlebars helpers that reference external js files to build advanced templates. This is super easy on server side javascript code all you have to do is make a reference, and it works. On a client that is not so simple. If your using something like browserify, your bundle of javascript files will not contain the files referanced inside of your templates. This module intends to help that out.

Handlebars Resolve will parse and find all paths inside of a template file and create a file that will referance the file as well as allow access to that file inside of your helpers.

Usage

make sure its installed.

var hbsResolve = require('handlebars-resolve');
 
hbsResolve({
  files: './templates/*.hbs',
  helper: 'view',
  outputFile: './resolves.js',
  basePath: './views/'
});

This is a fairly new repo, if you find a bug report it.

/handlebars-resolve/

    Package Sidebar

    Install

    npm i handlebars-resolve

    Weekly Downloads

    1

    Version

    0.4.3

    License

    MIT

    Last publish

    Collaborators

    • ~jcblw
    • etanlubeck