You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Hi! I want to use react-magic-move in my app. The catch is that I'm compiling everything with webpack and using the exclude option to prevent compiling every dependency.
When I try to build a file with require('react-magic-move') I get this error:
ERROR in ./~/react-magic-move/modules/components/MagicMove.js
Module parse failed: /Users/hugo.bessa/Sites/copag-cartas/node_modules/react-magic-move/modules/components/MagicMove.js Line 8: Unexpected token (
You may need an appropriate loader to handle this file type.
| displayName: 'MagicMoveClones',
|
| childrenWithPositions () {
| var children = [];
| React.Children.forEach(this.props.children, (child) => {
@ ./~/react-magic-move/modules/index.js 1:17-50
As I'm excluding my dependencies from the build step, and react-magic-move is exporting an ES6 module, the build step is failing.
Can react-magic-move export an ES5 CommonJS bundle or should I change my webpack configs?
The text was updated successfully, but these errors were encountered:
You need to add loader for jsx-loader?harmony transformer
For me, I have something like this: (I'm using react-jade for my React components in public folder)
Hi! I want to use react-magic-move in my app. The catch is that I'm compiling everything with webpack and using the exclude option to prevent compiling every dependency.
My
webpack.config.js
looks like this:When I try to build a file with
require('react-magic-move')
I get this error:As I'm excluding my dependencies from the build step, and
react-magic-move
is exporting an ES6 module, the build step is failing.Can
react-magic-move
export an ES5 CommonJS bundle or should I change my webpack configs?The text was updated successfully, but these errors were encountered: