UNPKG

sails-generate-frontend

Version:

Default generator for frontend code files in new Sails projects. Creates the default contents of the `assets/` folder when you run `sails new` on the command-line. Also creates a subset of the boilerplate Grunt task files (in `tasks/`); specifically, the

34 lines (31 loc) 689 B
/** * `coffee` * * --------------------------------------------------------------- * * Compile CoffeeScript files located in `assets/js` into Javascript * and generate new `.js` files in `.tmp/public/js`. * * For usage docs see: * https://github.com/gruntjs/grunt-contrib-coffee * */ module.exports = function(grunt) { grunt.config.set('coffee', { dev: { options: { bare: true, sourceMap: true, sourceRoot: './' }, files: [{ expand: true, cwd: 'assets/js/', src: ['**/*.coffee'], dest: '.tmp/public/js/', ext: '.js' }] } }); grunt.loadNpmTasks('grunt-contrib-coffee'); };