Skip to content

Instantly share code, notes, and snippets.

@flopshot
Created September 8, 2019 21:16
Show Gist options
  • Save flopshot/bc09d7291acb4e9732c586512e023ee5 to your computer and use it in GitHub Desktop.
Save flopshot/bc09d7291acb4e9732c586512e023ee5 to your computer and use it in GitHub Desktop.
WhiteLabelConfig.tsx with React Native Bridge calls
// WhiteLabelConfig.tsx
import { NativeModules } from 'react-native';
export default class WhiteLabelConfig {
public static readonly APP_NAME: string = NativeModules.WhiteLabelConfig.getAppName();
public static readonly PRIMARY_COLOR: string = NativeModules.WhiteLabelConfig.getPrimaryColor();
public static readonly PRIMARY_TEXT_COLOR: string = NativeModules.WhiteLabelConfig.getPrimaryTextColor();
public static readonly GREETING_TEXT: string = NativeModules.WhiteLabelConfig.getGreetingText();
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment