From 362936b00253c26dff8eb0a32f1c76d00320b7d9 Mon Sep 17 00:00:00 2001 From: Esteban Beltran Date: Mon, 24 Apr 2023 17:13:52 +0200 Subject: [PATCH] Build: Force same version of @emotion/react via webpack config (#66822) --- scripts/webpack/webpack.common.js | 3 +++ 1 file changed, 3 insertions(+) diff --git a/scripts/webpack/webpack.common.js b/scripts/webpack/webpack.common.js index cff93efbcd8..5413e9cc763 100644 --- a/scripts/webpack/webpack.common.js +++ b/scripts/webpack/webpack.common.js @@ -22,6 +22,9 @@ module.exports = { // some of data source plugins use global Prism object to add the language definition // we want to have same Prism object in core and in grafana/ui prismjs: require.resolve('prismjs'), + // some sub-dependencies use a different version of @emotion/react and generate warnings + // in the browser about @emotion/react loaded twice. We want to only load it once + '@emotion/react': require.resolve('@emotion/react'), }, modules: ['node_modules', path.resolve('public')], fallback: {