How to use the expo.Constants.manifest function in expo

To help you get started, we’ve selected a few expo 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 DefinitelyTyped / DefinitelyTyped / types / expo / v31 / expo-tests.tsx View on Github external
async () => {
    const appOwnerShip = Constants.appOwnership;
    const expoVersion = Constants.expoVersion;
    const installationId = Constants.installationId;
    const deviceId = Constants.deviceId;
    const deviceName = Constants.deviceName;
    const deviceYearClass = Constants.deviceYearClass;
    const isDevice = Constants.isDevice;
    const platform = Constants.platform;
    const sessionId = Constants.sessionId;
    const statusBarHeight = Constants.statusBarHeight;
    const systemFonts = Constants.systemFonts;
    const manifest = Constants.manifest;
    const linkingUri = Constants.linkingUri;
    const userAgent: string = await Constants.getWebViewUserAgentAsync();
};
// #endregion
github EvanBacon / Expo-Pillar-Valley / client / src / components / Button / Share.js View on Github external
onPress = async () => {
    const { score, screenshot: url } = this.props;
    // const url = await AssetUtils.uriAsync(image);
    const appName = Constants.manifest.name;
    const title = `${appName}`;
    const message = `OMG! I got ${score} points in @baconbrix ${appName}. ${storeUrl() || ''}`;
    Share.share(
      {
        message,
        title,
        url,
      },
      {
        tintColor: Constants.manifest.tintColor,
        excludedActivityTypes: [
          'com.apple.UIKit.activity.Print',
          'com.apple.UIKit.activity.AssignToContact',
          'com.apple.UIKit.activity.AddToReadingList',
          'com.apple.UIKit.activity.AirDrop',
          'com.apple.UIKit.activity.OpenInIBooks',
github watanabeyu / expo-firebase-instagram / src / navigation / MainTabNavigator.js View on Github external
},
    MeTab: {
      screen: createTabStack('MeTab', UserScreen),
      navigationOptions: () => ({
        tabBarIcon: MeTabIcon,
      }),
    },
  },
  // タブナビゲーション全体に関する設定値を記述します。
  {
    tabBarOptions: {
      showLabel: false, // タブのアイコンの下にラベルを表示しないようにします
      activeTintColor: '#333', // アクティブなタブの色を指定します。
      inactiveTintColor: '#bbb', // アクティブではないタブの色を指定します。
      style: { // タブの背景色を設定します。
        backgroundColor: Constants.manifest.extra.backgroundColor,
      },
    },
    tabBarComponent: TabBar, // タブ部分のコンポーネントを指定します。
    tabBarPosition: 'bottom', // タブバーの位置を指定します。
    animationEnabled: false, // アニメーションを無効にします。
    swipeEnabled: false, // スワイプによる画面遷移を無効にします。
  },
);
github elliotBraem / CupSave / src / data / services / auth.js View on Github external
return new Promise(async (resolve, reject) => {
      const {appId} = Constants.manifest.extra.facebook;
      const permissions = ['public_profile', 'email']; // required permissions

      const {type, token} = await Facebook.logInWithReadPermissionsAsync(appId, {permissions});

      switch (type) {
        case 'success': {
          await Firebase.auth().setPersistence(Firebase.auth.Auth.Persistence.LOCAL);
          const credential = Firebase.auth.FacebookAuthProvider.credential(token);
          const facebookProfile = await Firebase.auth().signInAndRetrieveDataWithCredential(credential);

          // do things with user's facebook profile data here
          const userRef = FBFirestore.collection('users').where('email', '==', facebookProfile.user.email);
          const {email} = facebookProfile.user;
          userRef.get().then(async querySnapshot => {
            if (!querySnapshot.empty) {
              // Contents of first document (only should be 1, emails are unique)
github expo / expo-three / example / components / Page.js View on Github external
static navigationOptions = ({ navigation }) => {
    const params = navigation.state.params || {};
    const title = params.title || Constants.manifest.name;
    const isPage = typeof params.data === 'function';
    let url;
    if (isPage) {
      url = params.data.url;
    }

    let headerRight;
    // Apple may sometimes reject your app for invoking SKStoreReview in a button, sometimes they won't... let's just disable it during review.
    if (!Settings.isInAppleReview) {
      headerRight = url ?  : ;
    }

    return {
      title,
      headerRight,
      headerTintColor: Colors.primaryColor,
github kriskate / pocket-dota / src / constants / Constants.js View on Github external
import React from 'react';
import { FontAwesome, Ionicons, MaterialIcons } from '@expo/vector-icons';
import Colors from './Colors';
import { Constants } from 'expo';
import { Platform } from 'react-native';

let _wikiVersion;
export const setWikiVersion = ({ appVersion, wikiVersion }) => {
  _wikiVersion = !appVersion ? null :
    `${appVersion}-${wikiVersion}`;
}
export const GET_WIKI_VERSION = () => _wikiVersion;

export const APP_VERSION = Constants.manifest.version;

export const ITEM_CONSTANTS = {
  DISSASEMBLE: 'DOTA_ITEM_DISASSEMBLE_ALWAYS',
}

export const SCREEN_LABELS = {
  HOME: 'Home',

  HEADER_WIKI: 'Wiki',
  HEROES: 'Heroes',
  ITEMS: 'Items',
  
  HEADER_GAME: 'Game info',
  PATCH_NOTES: 'Patch notes',
  TIPS: 'Tips',
github zxj963577494 / OverWatchTeams-React-Native-Expo / src / screens / Account / index.js View on Github external
{
              if (logined) {
                navigateTo('AccountGroupOrders')
              } else {
                Toast.info('请先登录', 1)
              }
            }}
          >
            
              
            
          
        
         '关于'}>
          
            
          
           {
              Linking.openURL(
                'https://github.com/zxj963577494/OverWatchTeams-React-Native'
              ).catch(err => Toast.fail('无法找到该网址', 1))
            }}
          >
            
              
            
          
           {
              Linking.openURL('https://github.com/zxj963577494').catch(err =>
github expo / expo-three / example / components / StoreReviewButton.js View on Github external
onPress={() => {
        if (StoreReview.isSupported()) {
          StoreReview.requestReview();
        } else {
          const { name } = Constants.manifest;
          Alert.alert(
            `Do you like ${name}?`,
            `Would you like to rate this app in the app store? It help's others discover ${name} too!`,
            [
              {
                text: 'OK',
                onPress: () => Linking.openURL(StoreReview.storeUrl()),
              },
              { text: 'Cancel', onPress: () => {}, style: 'cancel' },
            ],
            { cancelable: true }
          );
        }
      }}>
github kriskate / pocket-dota / src / utils / updaters.js View on Github external
export const app_needsUpdate = async () => {
  try {
    const newApp = await Expo.Updates.checkForUpdateAsync();

    if(newApp && newApp.isAvailable) {
      try {
        const { id, sdkVersion } = Constants.manifest;
    
        const res = await fetch(`https://expo.io/${id}/index.exp`, {
          headers: {
            ...noCache,
            'Exponent-SDK-Version': sdkVersion,
            'Exponent-Platform': Platform.OS,
          },
          method: 'GET',
        });
    
        const newVersion = (await res.json()).version;
        return { newVersion };

      } catch(e) {
        return { error: e };
      }