diff options
author | XhmikosR <xhmikosr@gmail.com> | 2016-04-02 10:03:04 +0300 |
---|---|---|
committer | XhmikosR <xhmikosr@gmail.com> | 2016-04-02 10:03:04 +0300 |
commit | ed0c12fd7109fd4cf16ef1b42874105566132192 (patch) | |
tree | 5fc7d7fe1e8418b1d3e75b2e1df99ed0bb01ab70 /Gruntfile.js | |
parent | 064fda0e802679e56e88db2910fdf5369dde6e4c (diff) |
Nuke grunt-line-remover.
Use concat's process function instead.
Diffstat (limited to 'Gruntfile.js')
-rw-r--r-- | Gruntfile.js | 17 |
1 files changed, 5 insertions, 12 deletions
diff --git a/Gruntfile.js b/Gruntfile.js index 6861ceba4a..fb7753170f 100644 --- a/Gruntfile.js +++ b/Gruntfile.js @@ -58,17 +58,6 @@ module.exports = function (grunt) { }, // JS build configuration - lineremover: { - es6Import: { - files: { - '<%= concat.bootstrap.dest %>': '<%= concat.bootstrap.dest %>' - }, - options: { - exclusionPattern: /^(import|export)/g - } - } - }, - babel: { dev: { options: { @@ -159,6 +148,10 @@ module.exports = function (grunt) { concat: { options: { + // Custom function to remove all export and import statements + process: function (src) { + return src.replace(/^(export|import).*/gm, ''); + }, stripBanners: false }, bootstrap: { @@ -447,7 +440,7 @@ module.exports = function (grunt) { grunt.registerTask('test-js', ['eslint', 'jscs:core', 'jscs:test', 'jscs:grunt', 'qunit']); // JS distribution task. - grunt.registerTask('dist-js', ['babel:dev', 'concat', 'lineremover', 'babel:dist', 'stamp', 'uglify:core', 'commonjs']); + grunt.registerTask('dist-js', ['babel:dev', 'concat', 'babel:dist', 'stamp', 'uglify:core', 'commonjs']); grunt.registerTask('test-scss', ['scsslint:core']); |