Skip to content

Instantly share code, notes, and snippets.

@dimitrov
Last active August 29, 2015 14:17
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save dimitrov/2377d2c3901b129f67a3 to your computer and use it in GitHub Desktop.
Save dimitrov/2377d2c3901b129f67a3 to your computer and use it in GitHub Desktop.
grunt-sass + grunt-contrib-watch
module.exports = function(grunt) {
grunt.initConfig({
pkg: grunt.file.readJSON('package.json'),
sass: {
options: {
sourceMap: true
},
dist: {
files: {
'styles/css/widgets.css': 'styles/sass/widgets.scss'
}
}
},
watch: {
sass: {
files: ['styles/sass/*.scss'],
tasks: ['sass:dist'],
},
livereload: {
options: { livereload: true },
files: ['styles/css/*.css', '*.html'],
},
},
});
grunt.loadNpmTasks('grunt-sass');
grunt.loadNpmTasks('grunt-contrib-watch');
grunt.registerTask('default', ['sass:dist', 'watch']);
};
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment