Skip to content

Request - set NODE_ENV="production" on prod build/serve #2110

Closed
@vicrep

Description

@vicrep

Please provide us with the following information:

  1. OS? Windows 7, 8 or 10. Linux (which distribution). Mac OSX (Yosemite? El Capitan?)
    OSX 10.11.6
  2. Versions. Please run ng --version. If there's nothing outputted, please run
    in a Terminal: node --version and paste the result here:
    angular-cli: 1.0.0-beta.11-webpack.9-2
    node: 6.5.0
    os: darwin x64
  3. Repro steps. Was this an app that wasn't created using the CLI? What change did you
    do on your code? etc.
    Include a npm package which uses React and run a prod-build/serve.
  4. The log given by the failure. Normally this include a stack trace and some
    more information.
    Warning: It looks like you're using a minified copy of the development build of React. When deploying React apps to production, make sure to use the production build which skips development warnings and is faster. See https://fb.me/react-minification for more details.
  5. Mention any other details that might be useful.
    This can be solved by setting the NODE_ENV to "production" on prod build (i.e. set process.env.NODE_ENV = 'production'; in build script). I'd be happy to submit a PR for this if interested.

Thanks! We'll be in touch soon.

Metadata

Metadata

Assignees

No one assigned

    Labels

    P5The team acknowledges the request but does not plan to address it, it remains open for discussion

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions