diff --git a/bin/webpack b/bin/webpack index 008ecb22f7c..14ed741a787 100755 --- a/bin/webpack +++ b/bin/webpack @@ -1,7 +1,7 @@ #!/usr/bin/env ruby ENV["RAILS_ENV"] ||= ENV["RACK_ENV"] || "development" -ENV["NODE_ENV"] ||= "development" +ENV["NODE_ENV"] ||= ENV["RAILS_ENV"] require "pathname" ENV["BUNDLE_GEMFILE"] ||= File.expand_path("../../Gemfile", diff --git a/config/webpack/test.js b/config/webpack/test.js new file mode 100644 index 00000000000..397a221905f --- /dev/null +++ b/config/webpack/test.js @@ -0,0 +1,8 @@ +const { merge } = require('webpack-merge'); + +const sharedConfig = require('./shared'); + +module.exports = merge(sharedConfig, { + mode: 'development', + cache: false, +});