From ef1e9816c1fdfef3a59514e2c20017b50f14b066 Mon Sep 17 00:00:00 2001 From: Andrew Miner Date: Sun, 28 Dec 2014 12:58:32 -0800 Subject: [PATCH] Enable client-side source maps for CoffeeScript --- Gruntfile.coffee | 14 ++++++++++++-- package.json | 4 +++- 2 files changed, 15 insertions(+), 3 deletions(-) diff --git a/Gruntfile.coffee b/Gruntfile.coffee index b607b0059..dd102ce40 100644 --- a/Gruntfile.coffee +++ b/Gruntfile.coffee @@ -1,4 +1,6 @@ ### +# Crafting Guide - Gruntfile.coffee +# # Copyright (c) 2014 by Redwood Labs # All rights reserved. ### @@ -16,7 +18,7 @@ module.exports = (grunt)-> ignore: ['jade'] transform: ['coffeeify'] browserifyOptions: - debug: false + debug: true extensions: ['.coffee'] files: './dist/js/main.js': ['./src/scripts/main.coffee'] @@ -64,6 +66,14 @@ module.exports = (grunt)-> './dist/css/jquery-ui.css': ['./lib/jquery-ui/jquery-ui.min.css'] './dist/css/mocha.css': ['./node_modules/mocha/mocha.css'] + exorcise: + main: + files: + './dist/js/main.js.map': ['./dist/js/main.js'] + test: + files: + './dist/js/test.js.map': ['./dist/js/test.js'] + jade: pages: options: @@ -120,4 +130,4 @@ module.exports = (grunt)-> grunt.registerTask 'default', 'build' - grunt.registerTask 'build', ['copy', 'sass', 'jade', 'browserify'] + grunt.registerTask 'build', ['copy', 'sass', 'jade', 'browserify', 'exorcise'] diff --git a/package.json b/package.json index 77c8ff474..228c03bf7 100644 --- a/package.json +++ b/package.json @@ -18,13 +18,15 @@ "homepage": "https://github.com/andrewminer/crafting-guide", "devDependencies": { "coffeeify": "^1.0.0", + "express": "^4.10.6", "grunt": "^0.4.5", "grunt-browserify": "^3.2.1", "grunt-contrib-clean": "^0.6.0", "grunt-contrib-copy": "^0.7.0", "grunt-contrib-jade": "^0.13.0", "grunt-contrib-sass": "^0.8.1", - "grunt-contrib-watch": "^0.6.1" + "grunt-contrib-watch": "^0.6.1", + "grunt-exorcise": "^0.2.0" }, "dependencies": { "backbone": "^1.1.2",