From 7507963b857164979eaf87fc97a29f35fbc2a532 Mon Sep 17 00:00:00 2001 From: Sebastian Sdorra Date: Thu, 17 Oct 2019 13:57:44 +0200 Subject: [PATCH] fix ui-extension import problems in stories --- .../.storybook/webpack.config.js | 40 +++++++++++++++++++ 1 file changed, 40 insertions(+) create mode 100644 scm-ui/ui-components/.storybook/webpack.config.js diff --git a/scm-ui/ui-components/.storybook/webpack.config.js b/scm-ui/ui-components/.storybook/webpack.config.js new file mode 100644 index 0000000000..4b810def95 --- /dev/null +++ b/scm-ui/ui-components/.storybook/webpack.config.js @@ -0,0 +1,40 @@ +module.exports = { + module: { + rules: [ + { + parser: { + system: false, + systemjs: false + } + }, + { + test: /\.(js|jsx)$/, + exclude: /node_modules/, + use: [ + { + loader: "babel-loader", + options: { + cacheDirectory: true, + presets: ["@scm-manager/babel-preset"] + } + } + ] + }, + { + test: /\.(css|scss|sass)$/i, + use: [ + // Creates `style` nodes from JS strings + "style-loader", + // Translates CSS into CommonJS + "css-loader", + // Compiles Sass to CSS + "sass-loader" + ] + }, + { + test: /\.(png|svg|jpg|gif|woff2?|eot|ttf)$/, + use: ["file-loader"] + } + ] + } +};