aboutsummaryrefslogtreecommitdiff
path: root/webpack.config.js
diff options
context:
space:
mode:
authorn-peugnet <n.peugnet@free.fr>2019-11-15 15:57:46 +0100
committern-peugnet <n.peugnet@free.fr>2019-11-15 15:57:46 +0100
commitc1843c0a2ef49de3d2030398f5c14549cc1791ab (patch)
tree22fd633cc2f19df053d1e7e2bb8e4a5d134890c8 /webpack.config.js
parente4bc65433283e0725a2e7bf07ae0c84f7905af17 (diff)
downloadwcms-c1843c0a2ef49de3d2030398f5c14549cc1791ab.tar.gz
wcms-c1843c0a2ef49de3d2030398f5c14549cc1791ab.zip
feat: load Sentry browser as an external script
- better way to check if we need to report errors in PHP - fix make file $(js_bundles) dependencies (add webpack conf) - update sentry-browser sdk and move it to dev requirements
Diffstat (limited to 'webpack.config.js')
-rw-r--r--webpack.config.js7
1 files changed, 5 insertions, 2 deletions
diff --git a/webpack.config.js b/webpack.config.js
index 8cd7764..9c6607d 100644
--- a/webpack.config.js
+++ b/webpack.config.js
@@ -19,8 +19,8 @@ module.exports = (env) => {
sentry: './src/sentry.js',
},
output: {
- filename: 'assets/js/[name].bundle.js',
- path: path.resolve(__dirname),
+ filename: '[name].bundle.js',
+ path: path.resolve(__dirname, 'assets', 'js'),
libraryTarget: 'window'
},
module: {
@@ -41,5 +41,8 @@ module.exports = (env) => {
singleQuote: true,
})
],
+ externals: {
+ '@sentry/browser': 'Sentry',
+ },
}
};