How to use the expo-font.processFontFamily function in expo-font

To help you get started, we’ve selected a few expo-font examples, based on popular ways it is used in public projects.

Secure your code as it's written. Use Snyk Code to scan source code in minutes - no build needed - and fix issues immediately.

github lightninglabs / lightning-app / mobile / App.js View on Github external
import 'node-libs-react-native/globals';
import { Platform, StyleSheet } from 'react-native';
import * as Font from 'expo-font';

// Configure expo-font to load .ttf files
// See: https://github.com/expo/expo/tree/master/packages/expo-font
StyleSheet.setStyleAttributePreprocessor('fontFamily', Font.processFontFamily);

// Polyfill ECMAScript Internationalization API on Android
// See: https://github.com/facebook/react-native/issues/19410
if (Platform.OS === 'android') {
  require('intl');
  require('intl/locale-data/jsonp/en-US');
}

import App from '../src/view/main-mobile';

module.exports = App;
github lightninglabs / lightning-app / mobile-bare / App.js View on Github external
import 'node-libs-react-native/globals';

// Polyfill ECMAScript Internationalization API on Android
// See: https://github.com/facebook/react-native/issues/19410
import 'intl';
import 'intl/locale-data/jsonp/en-US';

import { StyleSheet } from 'react-native';
import * as Font from 'expo-font';
StyleSheet.setStyleAttributePreprocessor('fontFamily', Font.processFontFamily);

import App from '../src/view/main-mobile';

module.exports = App;
github expo / expo / packages / expo / src / launch / withExpoRoot.tsx View on Github external
componentWillMount() {
      if (StyleSheet.setStyleAttributePreprocessor) {
        StyleSheet.setStyleAttributePreprocessor('fontFamily', Font.processFontFamily);
      }
      const { exp } = this.props;
      if (exp.notification) {
        Notifications._setInitialNotification(exp.notification);
      }
    }
github Marwan01 / food-converter / node_modules / expo / build / launch / withExpoRoot.js View on Github external
componentWillMount() {
            if (StyleSheet.setStyleAttributePreprocessor) {
                StyleSheet.setStyleAttributePreprocessor('fontFamily', Font.processFontFamily);
            }
            const { exp } = this.props;
            if (exp.notification) {
                Notifications._setInitialNotification(exp.notification);
            }
        }
        render() {
github expo / expo / packages / expo / build / launch / withExpoRoot.js View on Github external
componentWillMount() {
            if (StyleSheet.setStyleAttributePreprocessor) {
                StyleSheet.setStyleAttributePreprocessor('fontFamily', Font.processFontFamily);
            }
            const { exp } = this.props;
            if (exp.notification) {
                Notifications._setInitialNotification(exp.notification);
            }
        }
        render() {

expo-font

Load fonts at runtime and use them in React Native components.

MIT
Latest version published 16 days ago

Package Health Score

89 / 100
Full package analysis