Skip to content

Commit 52a5adb

Browse files
committed
Export direct-slot-children rule
1 parent 0a845c7 commit 52a5adb

File tree

2 files changed

+4
-2
lines changed

2 files changed

+4
-2
lines changed

src/configs/recommended.js

Lines changed: 3 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -8,14 +8,15 @@ module.exports = {
88
plugins: ['primer-react', 'github'],
99
extends: ['plugin:github/react'],
1010
rules: {
11+
'primer-react/direct-slot-children': 'error',
1112
'primer-react/no-deprecated-colors': 'warn',
1213
'primer-react/no-system-props': 'warn'
1314
},
1415
settings: {
1516
github: {
1617
components: {
17-
Link: { props: { as: { undefined: 'a', 'a': 'a', 'button': 'button'}}},
18-
Button: { default: 'button' },
18+
Link: {props: {as: {undefined: 'a', a: 'a', button: 'button'}}},
19+
Button: {default: 'button'}
1920
}
2021
},
2122
'jsx-a11y': {

src/index.js

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,6 @@
11
module.exports = {
22
rules: {
3+
'direct-slot-children': require('./rules/direct-slot-children'),
34
'no-deprecated-colors': require('./rules/no-deprecated-colors'),
45
'no-system-props': require('./rules/no-system-props')
56
},

0 commit comments

Comments
 (0)