Skip to content

Grunt plugin for converting HTML templates to a single JavaScript object

License

Notifications You must be signed in to change notification settings

zverev/grunt-html2jsobject

 
 

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

61 Commits
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

grunt-html2jsobject

Converts HTML templates to a single JavaScript object

Usage

module.exports = function(grunt) {
	grunt.initConfig({
		html2jsobject: {
        	subscriptions: {
        		options: {
        			newObject: false,
        			fileHeaderString: "var nsGmx = nsGmx || {};",
        			fileFooterString: "/* --- footer --- */"
        		},
        	   	container: "nsGmx.Templates.Subscriptions",
            	src: ['client/js/Controls/Subscriptions/*.html'],
        		dest: 'client/js/Controls/Subscriptions/Templates.js'
        	}
       	}
	});

	grunt.loadNpmTasks('grunt-html2jsobject');
}

About

Grunt plugin for converting HTML templates to a single JavaScript object

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages

  • JavaScript 100.0%