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
{{ message }}
This repository was archived by the owner on Jan 26, 2019. It is now read-only.
After changing the tsc target to es6, react-scripts-ts build fails during minification (I think). Running the development server (react-scripts-ts start) works fine on the es6 target.
Expected behavior
The build script should not fail.
Actual behavior
$ npm run build
> fooapp@0.1.0 build /private/tmp/fooapp
> react-scripts-ts build
Creating an optimized production build...
ts-loader: Using typescript@2.1.5 and /private/tmp/fooapp/tsconfig.json
Failed to compile.
static/js/main.33e14f74.js from UglifyJs
SyntaxError: Unexpected token: name (App) [./~/tslint-loader!./src/App.tsx:6,0]
Environment
Run these commands in the project folder and fill in their results:
npm ls react-scripts (if you haven’t ejected): react-scripts-ts@1.0.6
node -v: v7.4.0
npm -v: 4.1.2
Then, specify:
Operating system: macOS 10.12.3
Browser and version: N/A
Reproducible Demo
$ cd /tmp
$ create-react-app fooapp --scripts-version=react-scripts-ts
$ cd fooapp
$ sed -i '' 's/es5/es6/' tsconfig.json
$ npm run build