With importing of react-server-redux, command NODE_ENV=production react-server compile" fails.
The importing of ReduxAdapter is simple as below.
import {ReduxAdapter} from 'react-server-redux';
The command NODE_ENV=production react-server compile" fails with below message.
There were errors in the JavaScript compilation.
Home.ab7d7e279a3596bd49b0.bundle.js from UglifyJs
SyntaxError: Unexpected token: name (ReduxAdapter) [./~/react-server-redux/ReduxAdapter.js:1,0]
2017-03-27T06:09:24.996Z - error: [react-server-cli.src.commands.compile] message=There were errors in the JavaScript compilation., stack=Error: There were errors in the JavaScript compilation.
at handleCompilationErrors (/Users/morgan.cheng/github/react-server-demo/node_modules/react-server-cli/target/handleCompilationErrors.js:25:10)
The UglifyJS reports SyntaxError: Unexpected token: name (ReduxAdapter), even though npm start works fine.
With importing of
react-server-redux
, commandNODE_ENV=production react-server compile"
fails.The importing of
ReduxAdapter
is simple as below.The command
NODE_ENV=production react-server compile"
fails with below message.The UglifyJS reports
SyntaxError: Unexpected token: name (ReduxAdapter)
, even thoughnpm start
works fine.I have a minimalist app to repo this problem: https://github.com/mocheng/react-server-demo