Skip to content

External packages not transforming process.env.NODE_ENV #9641

@mridgway

Description

@mridgway

Do you want to request a feature or report a bug?

Bug

What is the current behavior?

process.env.NODE_ENV checks are being shipped to the browser.

What is the expected behavior?

In React, there is a browserify transform that converts process.env.NODE_ENV to the actual environment variable.

In package.json of React:

  "browserify": {
    "transform": [
      "loose-envify"
    ]
  }

Packages

  • prop-types
  • create-react-class
  • react-addons-create-fragment
  • react-transition-group

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions