Skip to content

Instantly share code, notes, and snippets.

@rvanzon
Last active April 11, 2016 14:37
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 rvanzon/fb4f5cb83b96f2c368232218412d95ca to your computer and use it in GitHub Desktop.
Save rvanzon/fb4f5cb83b96f2c368232218412d95ca to your computer and use it in GitHub Desktop.
Sails - add Stylus-support
// tasks/register/compileAssets.js
module.exports = function (grunt) {
grunt.registerTask('compileAssets', [
'clean:dev',
'jst:dev',
'less:dev',
'copy:dev',
'coffee:dev',
'stylus:dev'
]);
};
module.exports = function(grunt) {
grunt.config.set('stylus', {
dev: {
files: [{
expand: true,
cwd: 'assets/css/',
src: ['style.styl'], //Edit this to match your files
dest: '.tmp/public/css/',
ext: '.css'
}]
}
});
grunt.loadNpmTasks('grunt-contrib-stylus');
};
// tasks/register/syncAssets.js
module.exports = function (grunt) {
grunt.registerTask('syncAssets', [
'jst:dev',
'less:dev',
'sync:dev',
'coffee:dev',
'stylus:dev'
]);
};
@rvanzon
Copy link
Author

rvanzon commented Apr 11, 2016

And npm install grunt-contrib-stylus

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment