-
Notifications
You must be signed in to change notification settings - Fork 3
/
Copy pathsku.config.ts
47 lines (44 loc) · 1.1 KB
/
sku.config.ts
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
36
37
38
39
40
41
42
43
44
45
46
47
import type { SkuConfig } from 'sku';
const config: SkuConfig = {
rootResolution: false,
srcPaths: ['./src', './styles'],
dangerouslySetESLintConfig: (skuConfig) => ({
...skuConfig,
overrides: [
...(skuConfig.overrides ?? []),
{
files: [
// sku configuration
'./sku.config.ts',
// External type declarations
'*.d.ts',
// Storybook stories
'*.docs.tsx',
'*.stories.tsx',
],
rules: {
'import/no-default-export': 'off',
},
},
],
rules: {
...skuConfig.rules,
// https://basarat.gitbook.io/typescript/main-1/defaultisbad
'import/no-default-export': 'error',
'sort-imports': ['error', { ignoreDeclarationSort: true }],
},
settings: {
react: {
version: 'detect',
},
},
}),
dangerouslySetTSConfig: (tsConfig) => ({
...tsConfig,
include: [
'**/*', // Implicit default value if `include` is not set and `files` is not set
'.storybook/*', // 👈 Add this line
],
}),
};
export default config;