diff --git a/.jshintrc b/.jshintrc index de1188fd..f6cecbb0 100644 --- a/.jshintrc +++ b/.jshintrc @@ -16,6 +16,7 @@ "trailing": true, "undef": true, "unused": true, + "esnext": true, "predef": [ "console", diff --git a/Gruntfile.js b/Gruntfile.js index 8a8a73ca..eeed3a3b 100644 --- a/Gruntfile.js +++ b/Gruntfile.js @@ -18,7 +18,13 @@ module.exports = function(grunt) { browserifyOptions: { standalone: 'openpgp' }, - external: [ 'crypto', 'node-localstorage' ] + external: [ 'crypto', 'node-localstorage' ], + transform: [ + ["babelify", { + ignore: ['*.min.js'], + presets: ["es2015"] + }] + ] } }, openpgp_debug: { @@ -30,7 +36,13 @@ module.exports = function(grunt) { debug: true, standalone: 'openpgp' }, - external: [ 'crypto', 'node-localstorage' ] + external: [ 'crypto', 'node-localstorage' ], + transform: [ + ["babelify", { + ignore: ['*.min.js'], + presets: ["es2015"] + }] + ] } }, worker: { diff --git a/package.json b/package.json index 4aaad822..1da093c3 100644 --- a/package.json +++ b/package.json @@ -32,6 +32,8 @@ "test": "grunt test" }, "devDependencies": { + "babel-preset-es2015": "^6.3.13", + "babelify": "^7.2.0", "chai": "~3.4.1", "coveralls": "^2.11.2", "grunt": "~0.4.5",