return gulp.src(files)
.pipe(babel({
presets: ["react", "es2015" ],
plugins: [" transform-react-jsx"]
}))
.pipe(gulp.dest(dest));
I have tried with and without transform-react-jsx, Because I believe the reaction preset should also change jsx?
This is my .babelrc, but it doesn’t seem to make any difference, I read somewhere that you need to delete it in some cases to work. Tried it, did not help.
{
"presets": ["react", "es2015" ],
"plugins": ["transform-react-jsx"]
}< /pre>In my package.json:
"babel": "^6.5.2",
"babel-cli": " ^6.8.0",
"babel-plugin-transform-react-jsx": "^6.8.0",
"babel-preset-es2015": "~6.5.0",
"babel-preset-react": "^6.5.0",
"gulp-babel": "~6.1.2",
...I have Tried anything, but it didn’t change my code
You think it "can detect if the file in the stream has changed", just like the documentation says That way, but I think this is not the case.
No matter what I try, like
is not converted to React.createClass, the browser is obviously only in the firstreturn gulp.src(files)
.pipe(babel({
presets: ["react", "es2015" ],
plugins: ["transform-react-jsx"]
}))
.pipe(gulp.dest(dest));
Me Have tried with and without transform-react-jsx, because I believe the react preset should also change jsx?
This is my .babelrc, but it doesn't seem to make any difference, I read somewhere that you need to delete it in some cases to work. Tried it, did not help.
{
"presets": ["react", "es2015" ],
"plugins": ["transform-react-jsx"]
}< /pre>In my package.json:
"babel": "^6.5.2",
"babel-cli": " ^6.8.0",
"babel-plugin-transform-react-jsx": "^6.8.0",
"babel-preset-es2015": "~6.5.0",
"babel-preset-react": "^6.5.0",
"gulp-babel": "~6.1.2",
...I have Tried anything, but it didn't change my code
Obviously, there was a step between it that changed one step and broke it. Delete it Fix it for me.
You think it "can detect whether the file in the stream has changed", as the documentation says, but I think this is not the case.