Skip to content

Commit 98e37bd

Browse files
committed
Fix Storybook naming convention being ignored in Angular config
1 parent 63b2e40 commit 98e37bd

File tree

1 file changed

+17
-1
lines changed

1 file changed

+17
-1
lines changed

src/configs/angular.js

Lines changed: 17 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -10,11 +10,15 @@ import {
1010
CONFIG_FILE_PATTERNS,
1111
HTML_FILE_PATTERNS,
1212
negatePatterns,
13+
STORYBOOK_FILE_PATTERNS,
1314
TEST_FILE_PATTERNS,
1415
TEST_FILE_PATTERNS_INLINE_TEMPLATES,
1516
TYPESCRIPT_FILE_PATTERNS,
1617
} from '../lib/patterns.js';
17-
import { NAMING_CONVENTION_OPTIONS_ANGULAR } from '../lib/rule-options.js';
18+
import {
19+
NAMING_CONVENTION_OPTIONS_ANGULAR,
20+
NAMING_CONVENTION_OPTIONS_STORYBOOK,
21+
} from '../lib/rule-options.js';
1822
import typescript from './typescript.js';
1923

2024
export default tseslint.config(
@@ -173,6 +177,18 @@ export default tseslint.config(
173177
},
174178
],
175179
},
180+
{
181+
// duplicated from typescript config to re-apply over angular's naming convention
182+
name: 'code-pushup/angular/storybook/customized',
183+
files: STORYBOOK_FILE_PATTERNS,
184+
ignores: negatePatterns(TYPESCRIPT_FILE_PATTERNS),
185+
rules: {
186+
'@typescript-eslint/naming-convention': [
187+
'warn',
188+
...NAMING_CONVENTION_OPTIONS_STORYBOOK,
189+
],
190+
},
191+
},
176192
{
177193
name: 'code-pushup/angular/components/customized',
178194
files: [ANGULAR_COMPONENT_FILE_PATTERNS],

0 commit comments

Comments
 (0)