Build fails with create-react-app
compwright opened this issue · 1 comments
compwright commented
Steps to reproduce
create-react-app my-app
cd my-app
yarn add feathers-reactive
Load feathers-reactive
in one of the files, then:
yarn build
Expected behavior
The project should build successfully.
Actual behavior
feathersjs/feathers#774 is triggered, causing the build to fail with the following error:
$ react-scripts build
Creating an optimized production build...
Failed to compile.
Failed to minify the code from this file:
./node_modules/@feathersjs/commons/lib/utils.js:8
Read more here: http://bit.ly/2tRViJ9
error Command failed with exit code 1.
info Visit https://yarnpkg.com/en/docs/cli/run for documentation about this command.
ERROR: "build-js" exited with 1.
System configuration
Tell us about the applicable parts of your setup.
Module versions
- create-react-app 1.5.2
- feathers-reactive 0.6.0
NodeJS version: 8
Operating System: Mac OS X
Module Loader: Webpack (via create-react-app)
compwright commented
Note that this still happens even if you import the compiled version:
When you import, I've found that you have to:
import reactive from 'feathers-reactive/dist/feathers-reactive'
rather than:
import reactive from 'feathers-reactive'