Skip to content

isDev in webpack.config.js always truthy #530

Description

@prohazko2

Hi, noticed some kind of bug in webpack.config file
https://github.com/schrodinger/fixed-data-table-2/blob/master/webpack.config.js#L9

var isDev = JSON.stringify(process.env.NODE_ENV !== 'production');

isDev always evaluates to truthy string value after json stringification, so webpack always works in development mode, even for build-dist npm script here
https://github.com/schrodinger/fixed-data-table-2/blob/master/webpack.config.js#L62

Maybe something like

mode: isDev === 'true' ? 'development' : 'production',

would be better?

Activity

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions