Skip to content

Instantly share code, notes, and snippets.

Embed
What would you like to do?
Email builder grunt file.
module.exports = function(grunt){
'use strict';
grunt.initConfig({
connect: {
server: {
options: {
port: 9000,
base: 'src',
keepalive: true,
livereload: 4000
}
}
},
inlinecss: {
main: {
files: {
'dest/index.html': 'src/index.html'
}
}
},
watch: {
scripts: {
files: ['src/*'],
tasks: ['inlinecss'],
options: {
spawn: false,
livereload: 4000
}
},
livereload: {
// Here we watch the files the sass task will compile to
// These files are sent to the live reload server after sass compiles to them
options: { livereload: true },
files: ['dest/*'],
}
}
})
grunt.loadNpmTasks('grunt-contrib-connect');
grunt.loadNpmTasks('grunt-inline-css');
grunt.loadNpmTasks('grunt-contrib-watch');
grunt.registerTask('default', ['connect', 'watch']);
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
You can’t perform that action at this time.