Skip to content

Commit

Permalink
refactor: export types separately
Browse files Browse the repository at this point in the history
  • Loading branch information
yamankatby committed Mar 15, 2022
1 parent 9e63912 commit 715915f
Show file tree
Hide file tree
Showing 2 changed files with 127 additions and 55 deletions.
118 changes: 95 additions & 23 deletions src/index.ts
Original file line number Diff line number Diff line change
Expand Up @@ -16,26 +16,98 @@ export * from './hooks/use-surface-scale';
export * from './hooks/use-window-size';
export * from './hooks/use-window-size-value';

export { default as ActivityIndicator, ActivityIndicatorProps } from './ActivityIndicator';
export { default as AppBar, AppBarProps } from './AppBar';
export { default as Avatar, AvatarProps } from './Avatar';
export { default as Backdrop, BackdropProps } from './Backdrop';
export { default as BackdropSubheader, BackdropSubheaderProps } from './BackdropSubheader';
export { default as Badge, BadgeProps } from './Badge';
export { default as Banner, BannerProps } from './Banner';
export { default as Button, ButtonProps } from './Button';
export { default as Chip, ChipProps } from './Chip';
export { default as Dialog, DialogProps } from './Dialog';
export { default as DialogActions, DialogActionsProps } from './DialogActions';
export { default as DialogContent, DialogContentProps } from './DialogContent';
export { default as DialogHeader, DialogHeaderProps } from './DialogHeader';
export { default as Divider, DividerProps } from './Divider';
export { default as FAB, FABProps } from './FAB';
export { default as IconButton, IconButtonProps } from './IconButton';
export { default as ListItem, ListItemProps } from './ListItem';
export { default as Pressable, PressableProps } from './Pressable';
export { default as Snackbar, SnackbarProps } from './Snackbar';
export { default as Surface, SurfaceProps } from './Surface';
export { default as Switch, SwitchProps } from './Switch';
export { default as Text, TextProps } from './Text';
export { default as TextInput, TextInputProps } from './TextInput';
import type { ActivityIndicatorProps } from './ActivityIndicator';
import ActivityIndicator from './ActivityIndicator';
import type { AppBarProps } from './AppBar';
import AppBar from './AppBar';
import type { AvatarProps } from './Avatar';
import Avatar from './Avatar';
import type { BackdropProps } from './Backdrop';
import Backdrop from './Backdrop';
import type { BackdropSubheaderProps } from './BackdropSubheader';
import BackdropSubheader from './BackdropSubheader';
import type { BadgeProps } from './Badge';
import Badge from './Badge';
import type { BannerProps } from './Banner';
import Banner from './Banner';
import type { ButtonProps } from './Button';
import Button from './Button';
import type { ChipProps } from './Chip';
import Chip from './Chip';
import type { DialogProps } from './Dialog';
import Dialog from './Dialog';
import type { DialogActionsProps } from './DialogActions';
import DialogActions from './DialogActions';
import type { DialogContentProps } from './DialogContent';
import DialogContent from './DialogContent';
import type { DialogHeaderProps } from './DialogHeader';
import DialogHeader from './DialogHeader';
import type { DividerProps } from './Divider';
import Divider from './Divider';
import type { FABProps } from './FAB';
import FAB from './FAB';
import type { IconButtonProps } from './IconButton';
import IconButton from './IconButton';
import type { ListItemProps } from './ListItem';
import ListItem from './ListItem';
import type { PressableProps } from './Pressable';
import Pressable from './Pressable';
import type { SnackbarProps } from './Snackbar';
import Snackbar from './Snackbar';
import type { SurfaceProps } from './Surface';
import Surface from './Surface';
import type { SwitchProps } from './Switch';
import Switch from './Switch';
import type { TextProps } from './Text';
import Text from './Text';
import type { TextInputProps } from './TextInput';
import TextInput from './TextInput';

export {
ActivityIndicator,
AppBar,
Avatar,
Backdrop,
BackdropSubheader,
Badge,
Banner,
Button,
Chip,
Dialog,
DialogActions,
DialogContent,
DialogHeader,
Divider,
FAB,
IconButton,
ListItem,
Pressable,
Snackbar,
Surface,
Switch,
Text,
TextInput,
ActivityIndicatorProps,
AppBarProps,
AvatarProps,
BackdropProps,
BackdropSubheaderProps,
BadgeProps,
BannerProps,
ButtonProps,
ChipProps,
DialogProps,
DialogActionsProps,
DialogContentProps,
DialogHeaderProps,
DividerProps,
FABProps,
IconButtonProps,
ListItemProps,
PressableProps,
SnackbarProps,
SurfaceProps,
SwitchProps,
TextProps,
TextInputProps,
};
64 changes: 32 additions & 32 deletions yarn.lock
Original file line number Diff line number Diff line change
Expand Up @@ -2459,38 +2459,6 @@ __metadata:
languageName: node
linkType: hard

"@react-native-material/core@workspace:.":
version: 0.0.0-use.local
resolution: "@react-native-material/core@workspace:."
dependencies:
"@commitlint/config-conventional": ^11.0.0
"@react-native-community/eslint-config": ^2.0.0
"@release-it/conventional-changelog": ^2.0.0
"@types/chroma-js": ^2.1.3
"@types/jest": ^26.0.0
"@types/react": ^17.0.39
"@types/react-native": 0.66.16
chroma-js: ^2.4.2
commitlint: ^11.0.0
eslint: ^7.2.0
eslint-config-prettier: ^7.0.0
eslint-plugin-prettier: ^3.1.3
husky: ^6.0.0
jest: ^26.0.1
pod-install: ^0.1.0
prettier: ^2.0.5
react: 16.13.1
react-native: 0.63.4
react-native-builder-bob: ^0.18.0
react-native-flex-layout: ^0.1.2
release-it: ^14.2.2
typescript: ^4.1.3
peerDependencies:
react: "*"
react-native: "*"
languageName: unknown
linkType: soft

"@release-it/conventional-changelog@npm:^2.0.0":
version: 2.0.1
resolution: "@release-it/conventional-changelog@npm:2.0.1"
Expand Down Expand Up @@ -11061,6 +11029,38 @@ __metadata:
languageName: node
linkType: hard

"rn-material@workspace:.":
version: 0.0.0-use.local
resolution: "rn-material@workspace:."
dependencies:
"@commitlint/config-conventional": ^11.0.0
"@react-native-community/eslint-config": ^2.0.0
"@release-it/conventional-changelog": ^2.0.0
"@types/chroma-js": ^2.1.3
"@types/jest": ^26.0.0
"@types/react": ^17.0.39
"@types/react-native": 0.66.16
chroma-js: ^2.4.2
commitlint: ^11.0.0
eslint: ^7.2.0
eslint-config-prettier: ^7.0.0
eslint-plugin-prettier: ^3.1.3
husky: ^6.0.0
jest: ^26.0.1
pod-install: ^0.1.0
prettier: ^2.0.5
react: 16.13.1
react-native: 0.63.4
react-native-builder-bob: ^0.18.0
react-native-flex-layout: ^0.1.2
release-it: ^14.2.2
typescript: ^4.1.3
peerDependencies:
react: "*"
react-native: "*"
languageName: unknown
linkType: soft

"rsvp@npm:^4.8.4":
version: 4.8.5
resolution: "rsvp@npm:4.8.5"
Expand Down

1 comment on commit 715915f

@vercel
Copy link

@vercel vercel bot commented on 715915f Mar 15, 2022

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Please sign in to comment.