Skip to content

Commit

Permalink
Extract AppState TM type for react-native-codegen (#39546)
Browse files Browse the repository at this point in the history
Summary:
Pull Request resolved: #39546

Changelog: [Internal]

Reviewed By: rshest

Differential Revision: D49436860

fbshipit-source-id: d120e04f67430f66b5f1be453726b43805aeac81
  • Loading branch information
christophpurrer authored and facebook-github-bot committed Sep 20, 2023
1 parent 27979dc commit f31dada
Showing 1 changed file with 3 additions and 1 deletion.
4 changes: 3 additions & 1 deletion packages/react-native/Libraries/AppState/NativeAppState.js
Original file line number Diff line number Diff line change
Expand Up @@ -16,10 +16,12 @@ export type AppStateConstants = {|
initialAppState: string,
|};

export type AppState = {|app_state: string|};

export interface Spec extends TurboModule {
+getConstants: () => AppStateConstants;
+getCurrentAppState: (
success: (appState: {|app_state: string|}) => void,
success: (appState: AppState) => void,
error: (error: Object) => void,
) => void;

Expand Down

0 comments on commit f31dada

Please sign in to comment.