expose types off AppRegistry and do custom handling

Reviewed By: shergin

Differential Revision: D4557948

fbshipit-source-id: 439e486d1ef9e29c81cabf608943f7c62098a14b
This commit is contained in:
Kevin Gozali 2017-02-15 02:15:22 -08:00 committed by Facebook Github Bot
parent a512f6dcf6
commit 222856ea3a

View File

@ -29,21 +29,21 @@ if (__DEV__) {
type Task = (taskData: any) => Promise<void>;
type TaskProvider = () => Task;
type ComponentProvider = () => ReactClass<any>;
type AppConfig = {
export type ComponentProvider = () => ReactClass<any>;
export type AppConfig = {
appKey: string,
component?: ComponentProvider,
run?: Function,
section?: boolean,
};
type Runnable = {
export type Runnable = {
component?: ComponentProvider,
run: Function,
};
type Runnables = {
export type Runnables = {
[appKey: string]: Runnable,
};
type Registry = {
export type Registry = {
sections: Array<string>,
runnables: Runnables,
};