1 Star 1 Fork 2

小萨/EU.Admin.ReactNative

加入 Gitee
与超过 1200万 开发者一起发现、参与优秀开源项目,私有仓库也完全免费 :)
免费加入
文件
克隆/下载
app.config.ts 2.35 KB
一键复制 编辑 原始数据 按行查看 历史
/* eslint-disable max-lines-per-function */
import type { ConfigContext, ExpoConfig } from '@expo/config';
import type { AppIconBadgeConfig } from 'app-icon-badge/types';
import { ClientEnv, Env } from './env';
const appIconBadgeConfig: AppIconBadgeConfig = {
enabled: Env.APP_ENV !== 'production',
badges: [
{
text: Env.APP_ENV,
type: 'banner',
color: 'white',
},
{
text: Env.VERSION.toString(),
type: 'ribbon',
color: 'white',
},
],
};
export default ({ config }: ConfigContext): ExpoConfig => ({
...config,
name: Env.NAME,
description: `${Env.NAME} Mobile App`,
owner: Env.EXPO_ACCOUNT_OWNER,
scheme: Env.SCHEME,
slug: 'eu-cloud',
version: Env.VERSION.toString(),
orientation: 'portrait',
icon: './assets/icon.png',
userInterfaceStyle: 'automatic',
newArchEnabled: true,
runtimeVersion: '1.0.1',
updates: {
url: 'https://u.expo.dev/9d0f9588-d00f-40cf-a15c-ffd7e8bc7654', // 这里的project-id会由eas update:configure命令生成
enabled: true,
checkAutomatically: 'ON_LOAD',
fallbackToCacheTimeout: 0,
requestHeaders: {
'expo-runtime-version': '1.0.1',
'expo-channel-name': 'production',
},
},
assetBundlePatterns: ['**/*'],
ios: {
supportsTablet: true,
bundleIdentifier: Env.BUNDLE_ID,
config: {
usesNonExemptEncryption: false, // Avoid the export compliance warning on the app store
},
},
experiments: {
typedRoutes: true,
},
android: {
adaptiveIcon: {
foregroundImage: './assets/adaptive-icon.png',
backgroundColor: '#185A56',
},
package: Env.PACKAGE,
},
web: {
favicon: './assets/favicon.png',
bundler: 'metro',
},
plugins: [
[
'expo-splash-screen',
{
backgroundColor: '#185A56',
image: './assets/splash-icon.png',
imageWidth: 150,
},
],
[
'expo-font',
{
fonts: [
'./assets/fonts/Inter.ttf',
'node_modules/@ant-design/icons-react-native/fonts/antoutline.ttf',
'node_modules/@ant-design/icons-react-native/fonts/antfill.ttf',
],
},
],
'expo-localization',
'expo-router',
['app-icon-badge', appIconBadgeConfig],
['react-native-edge-to-edge'],
'expo-asset',
],
extra: {
...ClientEnv,
eas: {
projectId: Env.EAS_PROJECT_ID,
},
},
});
Loading...
马建仓 AI 助手
尝试更多
代码解读
代码找茬
代码优化
TypeScript
1
https://gitee.com/xiaochanghai520/eu.admin.reactnative.git
git@gitee.com:xiaochanghai520/eu.admin.reactnative.git
xiaochanghai520
eu.admin.reactnative
EU.Admin.ReactNative
develop

搜索帮助