react_on_rails
react_on_rails copied to clipboard
config.build_production_command as module cannot be used if using rails/webpacker for compiling
config.build_production_command cannot be used to compile the rails/webpacker way since
https://github.com/shakacode/react_on_rails/blob/master/lib/tasks/assets.rake#L10
unless ReactOnRails::WebpackerUtils.webpacker_webpack_production_config_exists?
The fix should be that if you want to define a custom module for building, that's OK and takes precedence. Otherwise, use the rails/webpacker build or a custom string.
Without this, production bundle caching won't work with rails/webpacker compilation.