Skip to content

Commit 8dd9cf7

Browse files
committed
chore: remove usage of "export *"
1 parent a6cc5b0 commit 8dd9cf7

File tree

115 files changed

+1033
-310
lines changed

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

115 files changed

+1033
-310
lines changed

packages/eslint-plugin/src/configs/base.js

Lines changed: 2 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -19,10 +19,9 @@ module.exports = {
1919
},
2020
overrides: [
2121
{
22-
files: '**/src/index.{ts,tsx,js}',
22+
files: '**/src/**/*.{ts,tsx,js}',
2323
rules: {
24-
// TODO: propagate to `error` once all packages barrel files have been fixed
25-
'@rnx-kit/no-export-all': ['warn', { expand: 'all' }],
24+
'@rnx-kit/no-export-all': ['error', { expand: 'all' }],
2625
},
2726
},
2827
],
Lines changed: 8 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1 +1,8 @@
1-
export * from './components/Button/index';
1+
export type { ButtonProps, ButtonSlots, ButtonState } from './components/Button/index';
2+
export {
3+
Button,
4+
buttonClassNames,
5+
renderButton_unstable,
6+
useButtonStyles_unstable,
7+
useButton_unstable,
8+
} from './components/Button/index';
Lines changed: 8 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1 +1,8 @@
1-
export * from './components/CompoundButton/index';
1+
export type { CompoundButtonProps, CompoundButtonSlots, CompoundButtonState } from './components/CompoundButton/index';
2+
export {
3+
CompoundButton,
4+
compoundButtonClassNames,
5+
renderCompoundButton_unstable,
6+
useCompoundButtonStyles_unstable,
7+
useCompoundButton_unstable,
8+
} from './components/CompoundButton/index';
Lines changed: 8 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1 +1,8 @@
1-
export * from './components/MenuButton/index';
1+
export type { MenuButtonProps, MenuButtonSlots, MenuButtonState } from './components/MenuButton/index';
2+
export {
3+
MenuButton,
4+
menuButtonClassNames,
5+
renderMenuButton_unstable,
6+
useMenuButtonStyles_unstable,
7+
useMenuButton_unstable,
8+
} from './components/MenuButton/index';
Lines changed: 8 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1 +1,8 @@
1-
export * from './components/SplitButton/index';
1+
export type { SplitButtonProps, SplitButtonSlots, SplitButtonState } from './components/SplitButton/index';
2+
export {
3+
SplitButton,
4+
renderSplitButton_unstable,
5+
splitButtonClassNames,
6+
useSplitButtonStyles_unstable,
7+
useSplitButton_unstable,
8+
} from './components/SplitButton/index';
Lines changed: 8 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1 +1,8 @@
1-
export * from './components/ToggleButton/index';
1+
export type { ToggleButtonProps, ToggleButtonState } from './components/ToggleButton/index';
2+
export {
3+
ToggleButton,
4+
renderToggleButton_unstable,
5+
toggleButtonClassNames,
6+
useToggleButtonStyles_unstable,
7+
useToggleButton_unstable,
8+
} from './components/ToggleButton/index';
Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
1-
export * from './Button';
1+
export { Button } from './Button';
22
// Explicit exports to omit ButtonCommons
33
export type { ButtonProps, ButtonSlots, ButtonState } from './Button.types';
4-
export * from './renderButton';
5-
export * from './useButton';
4+
export { renderButton_unstable } from './renderButton';
5+
export { useButton_unstable } from './useButton';
66
export { buttonClassNames, useButtonStyles_unstable } from './useButtonStyles.styles';
Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
1-
export * from './CompoundButton';
2-
export * from './CompoundButton.types';
3-
export * from './renderCompoundButton';
4-
export * from './useCompoundButton';
1+
export { CompoundButton } from './CompoundButton';
2+
export type { CompoundButtonProps, CompoundButtonSlots, CompoundButtonState } from './CompoundButton.types';
3+
export { renderCompoundButton_unstable } from './renderCompoundButton';
4+
export { useCompoundButton_unstable } from './useCompoundButton';
55
export { compoundButtonClassNames, useCompoundButtonStyles_unstable } from './useCompoundButtonStyles.styles';
Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
1-
export * from './MenuButton.types';
2-
export * from './MenuButton';
3-
export * from './renderMenuButton';
4-
export * from './useMenuButton';
1+
export type { MenuButtonProps, MenuButtonSlots, MenuButtonState } from './MenuButton.types';
2+
export { MenuButton } from './MenuButton';
3+
export { renderMenuButton_unstable } from './renderMenuButton';
4+
export { useMenuButton_unstable } from './useMenuButton';
55
export { menuButtonClassNames, useMenuButtonStyles_unstable } from './useMenuButtonStyles.styles';
Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
1-
export * from './SplitButton';
2-
export * from './SplitButton.types';
3-
export * from './renderSplitButton';
4-
export * from './useSplitButton';
1+
export { SplitButton } from './SplitButton';
2+
export type { SplitButtonProps, SplitButtonSlots, SplitButtonState } from './SplitButton.types';
3+
export { renderSplitButton_unstable } from './renderSplitButton';
4+
export { useSplitButton_unstable } from './useSplitButton';
55
export { splitButtonClassNames, useSplitButtonStyles_unstable } from './useSplitButtonStyles.styles';

0 commit comments

Comments
 (0)