Skip to content

Instantly share code, notes, and snippets.

Embed
What would you like to do?
diff --git a/tasks/js.js b/tasks/js.js
index 0caabc1..7c5319d 100644
--- a/tasks/js.js
+++ b/tasks/js.js
@@ -70,7 +70,10 @@ gulp.task('js', () => {
name: 'app',
plugins: [
plugins.rollupPluginReplace({'process.env.NODE_ENV': JSON.stringify( 'development' )}),
- plugins.rollupPluginJsx({ factory: 'React.createElement' }),
+ plugins.rollupPluginBabel({
+ exclude: 'node_modules/**',
+ presets: [['es2015', { modules: false }], 'react']
+ }),
plugins.rollupPluginCommonjs({}),
plugins.rollupPluginNodeResolve({ jsnext: true, main: true }),
plugins.rollupPluginIncludepaths({ paths: [paths.dev + '/script/'] })
@@ -93,8 +96,6 @@ gulp.task('js', () => {
.pipe(plugins.vinylSourceStream('app.js', paths.dev + '/script/'))
.pipe(plugins.vinylBuffer())
.pipe(plugins.sourcemaps.init({ loadMaps: true }))
- // Convert ES6
- .pipe(plugins.babel({ presets: ['es2015', 'react'] }))
// Write sourcemap
.pipe(plugins.sourcemaps.write('.'))
.pipe(gulp.dest(paths.tmp + '/script/'))
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
You can’t perform that action at this time.