kittoframework / kitto

Kitto is a framework for interactive dashboards written in Elixir
http://kitto.io/dashboards/sample
MIT License
955 stars 58 forks source link

Set NODE_ENV=production when building assets for production #63

Closed zorbash closed 7 years ago

zorbash commented 7 years ago

Currently an app deployed to production prints to the browser console:

Download the React DevTools for a better development experience: https://fb.me/react-devtools

According to https://github.com/facebook/react/issues/3877 this is due to the fact that NODE_ENV is not set to production. We have to tweak webpack.config.js so that when npm run build is invoked the proper environment is set.

if (TARGET === 'build') {
 // set NODE_ENV to production
}
zorbash commented 7 years ago

This doesn't seem necessary anymore. Can't reproduce it on master.