diff options
Diffstat (limited to 'config/webpack/loaders')
-rw-r--r-- | config/webpack/loaders/babel.js | 3 | ||||
-rw-r--r-- | config/webpack/loaders/sass.js | 7 |
2 files changed, 8 insertions, 2 deletions
diff --git a/config/webpack/loaders/babel.js b/config/webpack/loaders/babel.js index e17d2fa70..770c89aa7 100644 --- a/config/webpack/loaders/babel.js +++ b/config/webpack/loaders/babel.js @@ -7,7 +7,8 @@ module.exports = { exclude: /node_modules/, loader: 'babel-loader', options: { - forceEnv: env, + forceEnv: process.env.NODE_ENV || 'development', + sourceRoot: 'app/javascript', cacheDirectory: env === 'development' ? false : resolve(__dirname, '..', '..', '..', 'tmp', 'cache', 'babel-loader'), }, }; diff --git a/config/webpack/loaders/sass.js b/config/webpack/loaders/sass.js index bad09ceb4..920d5350f 100644 --- a/config/webpack/loaders/sass.js +++ b/config/webpack/loaders/sass.js @@ -17,6 +17,11 @@ module.exports = { sourceMap: true, }, }, - 'sass-loader', + { + loader: 'sass-loader', + options: { + includePaths: ['app/javascript'], + }, + }, ], }; |