-
-
Notifications
You must be signed in to change notification settings - Fork 2.5k
Expand file tree
/
Copy pathmain.js
More file actions
35 lines (32 loc) · 803 Bytes
/
main.js
File metadata and controls
35 lines (32 loc) · 803 Bytes
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
const path = require('path');
module.exports = {
stories: ['../src/**/*.stories.@(js|jsx|ts|tsx)'],
addons: [
'@storybook/addon-docs',
'@storybook/addon-controls',
'@storybook/addon-actions',
'@storybook/addon-viewport'
],
webpackFinal: async config => {
config.module.rules[0].use = [require.resolve('swc-loader')];
config.module.rules.push({
test: /\.scss$/,
use: ['style-loader', 'css-loader', 'postcss-loader', 'sass-loader'].map(
require.resolve
)
});
config.resolve.alias['chartist-dev/styles$'] = path.resolve(
__dirname,
'..',
'src',
'styles',
'index.scss'
);
config.resolve.alias['chartist-dev$'] = path.resolve(
__dirname,
'..',
'src'
);
return config;
}
};