Skip to content

Commit

Permalink
Export EmitterSubscription TypeScript Type (facebook#36632)
Browse files Browse the repository at this point in the history
Summary:
Pull Request resolved: facebook#36632

Discovered when bumping the RN documentation to typecheck against 0.72, facebook#36109 removed the `EmitterSubscription` type which should be kept public.

Changelog:
[General][Fixed] -  Export EmitterSubscription TypeScript Type

Reviewed By: cortinico

Differential Revision: D44375081

fbshipit-source-id: c8dbd5694d3a728a0a2091210894d27c9d84a012
  • Loading branch information
NickGerleman authored and facebook-github-bot committed Apr 17, 2023
1 parent 4e97283 commit eb83356
Show file tree
Hide file tree
Showing 2 changed files with 6 additions and 0 deletions.
2 changes: 2 additions & 0 deletions packages/react-native/types/__typetests__/index.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -40,6 +40,8 @@ import {
DrawerLayoutAndroid,
DrawerSlideEvent,
DynamicColorIOS,
EmitterSubscription,
EventSubscription,
FlatList,
FlatListProps,
GestureResponderEvent,
Expand Down
4 changes: 4 additions & 0 deletions packages/react-native/types/index.d.ts
Original file line number Diff line number Diff line change
Expand Up @@ -147,6 +147,10 @@ export * from '../Libraries/Utilities/Platform';
export * from '../Libraries/Vibration/Vibration';
export * from '../Libraries/YellowBox/YellowBoxDeprecated';
export * from '../Libraries/vendor/core/ErrorUtils';
export {
EmitterSubscription,
EventSubscription,
} from '../Libraries/vendor/emitter/EventEmitter';

export * from './public/DeprecatedPropertiesAlias';
export * from './public/Insets';
Expand Down

0 comments on commit eb83356

Please sign in to comment.