Skip to content

Fails to build on create-react-app: Publish ES5 to NPM #4

@glcheetham

Description

@glcheetham

When building a project using merge-options on create-react-app, react-scripts build will give the following error:

> react-scripts build

Creating an optimized production build...
Failed to compile.

Failed to minify the code from this file:

 	./node_modules/merge-options/index.js:11

Read more here: http://bit.ly/2tRViJ9

This link to the create-react-app documentation explains the problem in more detail:

Some third-party packages don't compile their code to ES5 before publishing to npm. This often causes problems in the ecosystem because neither browsers (except for most modern versions) nor some tools currently support all ES6 features. We recommend to publish code on npm as ES5 at least for a few more years.

Metadata

Metadata

Assignees

No one assigned

    Labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions