Skip to content

Latest commit

 

History

History
60 lines (42 loc) · 1.59 KB

README.md

File metadata and controls

60 lines (42 loc) · 1.59 KB

grunt-dustjs

Grunt task to compile Dust.js templates.

Getting Started

Install this grunt plugin next to your project's grunt.js gruntfile with: npm install grunt-dustjs.

Then add this line to your project's grunt.js gruntfile:

grunt.loadNpmTasks('grunt-dustjs');

Documentation

Inside your grunt.js file, add a section named dustjs. This section specifies the Dust.js template files to compile.

files object

This defines what files this task will process and should contain key:value pairs.

The key (destination) should be an unique filepath (supports grunt.template) and the value (source) should be a filepath or an array of filepaths (supports minimatch).

Example

// project configuration
grunt.initConfig({
  dustjs: {
    compile: {
      files: {
        "js/templates.js": ["src/templates/**/*.html"]
      }
    }
  },
});

Contributing

In lieu of a formal styleguide, take care to maintain the existing coding style. Add unit tests for any new or changed functionality. Lint and test your code using grunt.

Release History

  • 25/09/2012 - 0.1.2: Initial release.

License

Copyright (c) 2012 Stanislav Lesnikov Licensed under the MIT license.