Skip to content

Commit

Permalink
include subdirs in rule file include globs
Browse files Browse the repository at this point in the history
  • Loading branch information
yannbf committed Sep 26, 2024
1 parent 9dd8662 commit a4a9835
Show file tree
Hide file tree
Showing 7 changed files with 7 additions and 7 deletions.
2 changes: 1 addition & 1 deletion lib/configs/addon-interactions.ts
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,7 @@ export = {
plugins: ['storybook'],
overrides: [
{
files: ['*.stories.@(ts|tsx|js|jsx|mjs|cjs)', '*.story.@(ts|tsx|js|jsx|mjs|cjs)'],
files: ['**/*.stories.@(ts|tsx|js|jsx|mjs|cjs)', '**/*.story.@(ts|tsx|js|jsx|mjs|cjs)'],
rules: {
'react-hooks/rules-of-hooks': 'off',
'import/no-anonymous-default-export': 'off',
Expand Down
2 changes: 1 addition & 1 deletion lib/configs/csf.ts
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,7 @@ export = {
plugins: ['storybook'],
overrides: [
{
files: ['*.stories.@(ts|tsx|js|jsx|mjs|cjs)', '*.story.@(ts|tsx|js|jsx|mjs|cjs)'],
files: ['**/*.stories.@(ts|tsx|js|jsx|mjs|cjs)', '**/*.story.@(ts|tsx|js|jsx|mjs|cjs)'],
rules: {
'react-hooks/rules-of-hooks': 'off',
'import/no-anonymous-default-export': 'off',
Expand Down
2 changes: 1 addition & 1 deletion lib/configs/flat/addon-interactions.ts
Original file line number Diff line number Diff line change
Expand Up @@ -14,7 +14,7 @@ export = [
},
{
name: 'storybook:addon-interactions:stories-rules',
files: ['*.stories.@(ts|tsx|js|jsx|mjs|cjs)', '*.story.@(ts|tsx|js|jsx|mjs|cjs)'],
files: ['**/*.stories.@(ts|tsx|js|jsx|mjs|cjs)', '**/*.story.@(ts|tsx|js|jsx|mjs|cjs)'],
rules: {
'react-hooks/rules-of-hooks': 'off',
'import/no-anonymous-default-export': 'off',
Expand Down
2 changes: 1 addition & 1 deletion lib/configs/flat/csf.ts
Original file line number Diff line number Diff line change
Expand Up @@ -14,7 +14,7 @@ export = [
},
{
name: 'storybook:csf:stories-rules',
files: ['*.stories.@(ts|tsx|js|jsx|mjs|cjs)', '*.story.@(ts|tsx|js|jsx|mjs|cjs)'],
files: ['**/*.stories.@(ts|tsx|js|jsx|mjs|cjs)', '**/*.story.@(ts|tsx|js|jsx|mjs|cjs)'],
rules: {
'react-hooks/rules-of-hooks': 'off',
'import/no-anonymous-default-export': 'off',
Expand Down
2 changes: 1 addition & 1 deletion lib/configs/flat/recommended.ts
Original file line number Diff line number Diff line change
Expand Up @@ -14,7 +14,7 @@ export = [
},
{
name: 'storybook:recommended:stories-rules',
files: ['*.stories.@(ts|tsx|js|jsx|mjs|cjs)', '*.story.@(ts|tsx|js|jsx|mjs|cjs)'],
files: ['**/*.stories.@(ts|tsx|js|jsx|mjs|cjs)', '**/*.story.@(ts|tsx|js|jsx|mjs|cjs)'],
rules: {
'react-hooks/rules-of-hooks': 'off',
'import/no-anonymous-default-export': 'off',
Expand Down
2 changes: 1 addition & 1 deletion lib/configs/recommended.ts
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,7 @@ export = {
plugins: ['storybook'],
overrides: [
{
files: ['*.stories.@(ts|tsx|js|jsx|mjs|cjs)', '*.story.@(ts|tsx|js|jsx|mjs|cjs)'],
files: ['**/*.stories.@(ts|tsx|js|jsx|mjs|cjs)', '**/*.story.@(ts|tsx|js|jsx|mjs|cjs)'],
rules: {
'react-hooks/rules-of-hooks': 'off',
'import/no-anonymous-default-export': 'off',
Expand Down
2 changes: 1 addition & 1 deletion tests/integrations/flat-config/eslint.config.js
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@ import plugin from 'eslint-plugin-storybook'
export default [
...plugin.configs['flat/recommended'],
{
files: ['*.stories.@(ts|tsx|js|jsx|mjs|cjs)', '*.story.@(ts|tsx|js|jsx|mjs|cjs)'],
files: ['**/*.stories.@(ts|tsx|js|jsx|mjs|cjs)', '**/*.story.@(ts|tsx|js|jsx|mjs|cjs)'],
rules: {
'storybook/story-exports': 'warn',
},
Expand Down

0 comments on commit a4a9835

Please sign in to comment.