n8n/packages/design-system/.storybook/main.js
कारतोफ्फेलस्क्रिप्ट™ 1821bb0699
fix: Lint typescript stories (no-changelog) (#4723)
* fix: Lint typescript stories (no-changelog)

* import StoryFn as type
2022-11-25 13:00:59 +01:00

57 lines
1.1 KiB
JavaScript

const path = require('path');
/**
* @type {import('@storybook/core-common').StorybookConfig}
*/
module.exports = {
stories: ['../src/**/*.stories.mdx', '../src/**/*.stories.{ts,js}'],
addons: [
'@storybook/addon-links',
'@storybook/addon-essentials',
{
name: '@storybook/addon-postcss',
options: {
postcssLoaderOptions: {
implementation: require('postcss'),
},
},
},
'storybook-addon-designs',
'storybook-addon-themes',
],
webpackFinal: async (config) => {
config.module.rules.push({
test: /\.scss$/,
oneOf: [
{
resourceQuery: /module/,
use: [
'vue-style-loader',
{
loader: 'css-loader',
options: {
modules: {
localIdentName: '[path][name]__[local]--[hash:base64:5]',
},
},
},
'sass-loader',
],
include: path.resolve(__dirname, '../'),
},
{
use: ['vue-style-loader', 'css-loader', 'sass-loader'],
include: path.resolve(__dirname, '../'),
},
],
});
config.resolve.alias = {
...config.resolve.alias,
'@/': path.resolve(__dirname, '../src/'),
};
return config;
},
};