expo-constants 常量
import Constants from "expo-constants";
const Constants = {
"__expo_module_name__": "ExponentConstants", // 内部属性开发无用
"addListener": [Function addListener], // 用于添加和移除事件监听器,以响应某些运行时事件的变化
"appOwnership": "expo", // 在 Expo Go 中运行时返回expo ,否则返回null 。区分独立应用(已从 Expo 分离)和 Expo 托管应用很有用
"deviceName": "M2007J3SC", // 提供当前设备的名称。用于调试或记录目的,以识别正在运行应用的设备
"easConfig": {}, // 标准 EAS 配置对象
"emit": [Function emit],
"executionEnvironment": "storeClient", // 执行环境
"experienceUrl": "exp://10.0.0.6:8083", // 体验网址
"expoConfig": { // expo 配置信息
"_internal": {
"dynamicConfigPath": null,
"isDebug": false,
"packageJsonPath": "/Users/paul/code/project/react-native/react-native-expo-examples/package.json",
"projectRoot": "/Users/paul/code/project/react-native/react-native-expo-examples",
"staticConfigPath": "/Users/paul/code/project/react-native/react-native-expo-examples/app.json"
},
"android": { "adaptiveIcon": [Object] },
"hostUri": "10.0.0.6:8083",
"icon": "./assets/icon.png",
"iconUrl": "http://10.0.0.6:8083/assets/./assets/icon.png",
"ios": { "supportsTablet": true },
"name": "react-native-expo-examples",
"orientation": "portrait",
"platforms": ["ios", "android", "web"],
"sdkVersion": "51.0.0",
"slug": "react-native-expo-examples",
"splash": {
"backgroundColor": "#ffffff",
"image": "./assets/splash.png",
"imageUrl": "http://10.0.0.6:8083/assets/./assets/splash.png",
"resizeMode": "contain"
},
"userInterfaceStyle": "light",
"version": "1.0.0",
"web": { "favicon": "./assets/favicon.png" }
},
"expoGoConfig": { // expogo 设置
"__flipperHack": "React Native packager is running", "debuggerHost": "10.0.0.6:8083",
"developer": { "projectRoot": "/Users/paul/code/project/react-native/react-native-expo-examples", "tool": "expo-cli" },
"mainModuleName": "node_modules/expo/AppEntry", "packagerOpts": { "dev": true }
},
"expoVersion": "2.31.1", // expogo 版本
"getWebViewUserAgentAsync": [Function getWebViewUserAgentAsync], // 获取用户代理字符串
"intentUri": "exp://10.0.0.6:8083",
"isDetached": false,
"isHeadless": false,
"linkingUri": "exp://10.0.0.6:8083",
"listenerCount": [Function listenerCount],
"manifest": null,
"manifest2": { // Expo 服务生成的,包含了更多关于应用的信息,如资产、创建时间等。
"assets": [],
"createdAt": "2024-10-19T14:28:41.878Z",
"extra": {
"eas": [Object],
"expoClient": [Object],
"expoGo": [Object],
"scopeKey": "@anonymous/react-native-expo-examples-7b47b5b5-95f1-48a7-9c1e-7b1a2807e244"
},
"id": "79b45ea1-82af-43bd-924e-ff51199b8f0e",
"isVerified": true,
"launchAsset": { "contentType": "application/javascript", "key": "bundle", "url": "http://10.0.0.6:8083/node_modules/expo/AppEntry.bundle?platform=android&dev=true&hot=false&lazy=true&transform.engine=hermes&transform.bytecode=true&transform.routerRoot=app" },
"metadata": {},
"runtimeVersion": "exposdk:51.0.0"
},
"nativeAppVersion": "2.31.1", // expogo 版本
"nativeBuildVersion": 248,
"platform": { // 已弃用。使用expo-device的Device.modelId 。
"android": { "versionCode": null }
},
"removeAllListeners": [Function removeAllListeners],
"removeListener": [Function removeListener],
"removeSubscription": [Function removeSubscription],
"sessionId": "145125b9-2bd6-4790-8b95-e7fd31187570",
"statusBarHeight": 32, // 设备的默认状态栏高度。不考虑使用位置跟踪或通话时的变化。
"supportedExpoSdks": ["51.0.0"],
"systemFonts": [ // 系统字体
"normal",
"notoserif",
"sans-serif",
"sans-serif-light",
"sans-serif-thin",
"sans-serif-condensed",
"sans-serif-medium",
"serif",
"Roboto",
"monospace"],
"systemVersion": "12" // 已弃用。使用expo-device的Device.osVersion 。
}
洗尽铅华始见金,褪去浮华归本真
分类:
expo
【推荐】国内首个AI IDE,深度理解中文开发场景,立即下载体验Trae
【推荐】编程新体验,更懂你的AI,立即体验豆包MarsCode编程助手
【推荐】抖音旗下AI助手豆包,你的智能百科全书,全免费不限次数
【推荐】轻量又高性能的 SSH 工具 IShell:AI 加持,快人一步
· AI与.NET技术实操系列:基于图像分类模型对图像进行分类
· go语言实现终端里的倒计时
· 如何编写易于单元测试的代码
· 10年+ .NET Coder 心语,封装的思维:从隐藏、稳定开始理解其本质意义
· .NET Core 中如何实现缓存的预热?
· 分享一个免费、快速、无限量使用的满血 DeepSeek R1 模型,支持深度思考和联网搜索!
· 25岁的心里话
· 基于 Docker 搭建 FRP 内网穿透开源项目(很简单哒)
· ollama系列01:轻松3步本地部署deepseek,普通电脑可用
· 按钮权限的设计及实现