@expo/cli 56.1.5 → 56.1.6
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/build/bin/cli +1 -1
- package/build/src/events/index.js +1 -1
- package/build/src/export/embed/exportEmbedAsync.js +1 -1
- package/build/src/export/embed/exportEmbedAsync.js.map +1 -1
- package/build/src/export/embed/exportServer.js +1 -1
- package/build/src/export/embed/exportServer.js.map +1 -1
- package/build/src/export/exportApp.js +1 -1
- package/build/src/export/exportApp.js.map +1 -1
- package/build/src/export/publicFolder.js +19 -1
- package/build/src/export/publicFolder.js.map +1 -1
- package/build/src/login/index.js +25 -5
- package/build/src/login/index.js.map +1 -1
- package/build/src/run/android/resolveLaunchProps.js +4 -1
- package/build/src/run/android/resolveLaunchProps.js.map +1 -1
- package/build/src/start/doctor/dependencies/reactNativeTv.js +149 -0
- package/build/src/start/doctor/dependencies/reactNativeTv.js.map +1 -0
- package/build/src/start/doctor/dependencies/validateDependenciesVersions.js +28 -3
- package/build/src/start/doctor/dependencies/validateDependenciesVersions.js.map +1 -1
- package/build/src/start/server/DevToolsPlugin.js +26 -1
- package/build/src/start/server/DevToolsPlugin.js.map +1 -1
- package/build/src/start/server/DevToolsPluginCliExtensionExecutor.js +57 -22
- package/build/src/start/server/DevToolsPluginCliExtensionExecutor.js.map +1 -1
- package/build/src/start/server/DevToolsPluginCliExtensionResults.js +29 -0
- package/build/src/start/server/DevToolsPluginCliExtensionResults.js.map +1 -1
- package/build/src/start/server/MCPDevToolsPluginCLIExtensions.js +15 -5
- package/build/src/start/server/MCPDevToolsPluginCLIExtensions.js.map +1 -1
- package/build/src/start/server/UrlCreator.js +4 -0
- package/build/src/start/server/UrlCreator.js.map +1 -1
- package/build/src/start/server/createMCPDevToolsExtensionSchema.js +13 -1
- package/build/src/start/server/createMCPDevToolsExtensionSchema.js.map +1 -1
- package/build/src/start/server/metro/MetroBundlerDevServer.js +44 -0
- package/build/src/start/server/metro/MetroBundlerDevServer.js.map +1 -1
- package/build/src/start/server/metro/createServerComponentsMiddleware.js +13 -13
- package/build/src/start/server/metro/createServerComponentsMiddleware.js.map +1 -1
- package/build/src/start/server/metro/dev-server/createMessageSocket.js +13 -2
- package/build/src/start/server/metro/dev-server/createMessageSocket.js.map +1 -1
- package/build/src/start/server/metro/dev-server/createMetroMiddleware.js +2 -1
- package/build/src/start/server/metro/dev-server/createMetroMiddleware.js.map +1 -1
- package/build/src/start/server/metro/instantiateMetro.js +5 -4
- package/build/src/start/server/metro/instantiateMetro.js.map +1 -1
- package/build/src/start/server/metro/router.js +10 -1
- package/build/src/start/server/metro/router.js.map +1 -1
- package/build/src/start/server/middleware/OpenMiddleware.js +150 -0
- package/build/src/start/server/middleware/OpenMiddleware.js.map +1 -0
- package/build/src/start/server/middleware/RuntimeRedirectMiddleware.js +13 -4
- package/build/src/start/server/middleware/RuntimeRedirectMiddleware.js.map +1 -1
- package/build/src/start/server/middleware/ServeStaticMiddleware.js +2 -9
- package/build/src/start/server/middleware/ServeStaticMiddleware.js.map +1 -1
- package/build/src/start/server/middleware/openHandlers.js +157 -0
- package/build/src/start/server/middleware/openHandlers.js.map +1 -0
- package/build/src/start/server/webTemplate.js +3 -5
- package/build/src/start/server/webTemplate.js.map +1 -1
- package/build/src/utils/net.js +7 -1
- package/build/src/utils/net.js.map +1 -1
- package/build/src/utils/tar.js +2 -2
- package/build/src/utils/tar.js.map +1 -1
- package/build/src/utils/telemetry/clients/FetchClient.js +1 -1
- package/build/src/utils/telemetry/utils/context.js +1 -1
- package/package.json +14 -14
|
@@ -0,0 +1,157 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
Object.defineProperty(exports, "__esModule", {
|
|
3
|
+
value: true
|
|
4
|
+
});
|
|
5
|
+
function _export(target, all) {
|
|
6
|
+
for(var name in all)Object.defineProperty(target, name, {
|
|
7
|
+
enumerable: true,
|
|
8
|
+
get: Object.getOwnPropertyDescriptor(all, name).get
|
|
9
|
+
});
|
|
10
|
+
}
|
|
11
|
+
_export(exports, {
|
|
12
|
+
get createInfoHandler () {
|
|
13
|
+
return createInfoHandler;
|
|
14
|
+
},
|
|
15
|
+
get createOpen () {
|
|
16
|
+
return createOpen;
|
|
17
|
+
},
|
|
18
|
+
get resolveOpenInfo () {
|
|
19
|
+
return resolveOpenInfo;
|
|
20
|
+
}
|
|
21
|
+
});
|
|
22
|
+
function createInfoHandler(deps) {
|
|
23
|
+
return ({ platform, runtime })=>resolveOpenInfo({
|
|
24
|
+
platform,
|
|
25
|
+
runtime
|
|
26
|
+
}, deps);
|
|
27
|
+
}
|
|
28
|
+
async function resolveOpenInfo({ platform, runtime }, deps) {
|
|
29
|
+
// Snapshot the live state once per request so the response is internally consistent even if a
|
|
30
|
+
// toggle happens between sub-resolutions.
|
|
31
|
+
const scheme = deps.urlCreator.getScheme();
|
|
32
|
+
const isDevClient = deps.getIsDevClient();
|
|
33
|
+
const isRedirectPageEnabled = deps.getIsRedirectPageEnabled();
|
|
34
|
+
const availableRuntimes = isDevClient ? [
|
|
35
|
+
'custom'
|
|
36
|
+
] : isRedirectPageEnabled ? [
|
|
37
|
+
'expo',
|
|
38
|
+
'custom'
|
|
39
|
+
] : [
|
|
40
|
+
'expo'
|
|
41
|
+
];
|
|
42
|
+
if (platform) {
|
|
43
|
+
return {
|
|
44
|
+
scheme,
|
|
45
|
+
availableRuntimes,
|
|
46
|
+
...await resolvePlatformInfo(platform, runtime, deps, {
|
|
47
|
+
isDevClient,
|
|
48
|
+
isRedirectPageEnabled
|
|
49
|
+
})
|
|
50
|
+
};
|
|
51
|
+
}
|
|
52
|
+
const [ios, android, web] = await Promise.all([
|
|
53
|
+
resolvePlatformInfo('ios', runtime, deps, {
|
|
54
|
+
isDevClient,
|
|
55
|
+
isRedirectPageEnabled
|
|
56
|
+
}),
|
|
57
|
+
resolvePlatformInfo('android', runtime, deps, {
|
|
58
|
+
isDevClient,
|
|
59
|
+
isRedirectPageEnabled
|
|
60
|
+
}),
|
|
61
|
+
resolvePlatformInfo('web', runtime, deps, {
|
|
62
|
+
isDevClient,
|
|
63
|
+
isRedirectPageEnabled
|
|
64
|
+
})
|
|
65
|
+
]);
|
|
66
|
+
return {
|
|
67
|
+
scheme,
|
|
68
|
+
availableRuntimes,
|
|
69
|
+
platforms: {
|
|
70
|
+
ios,
|
|
71
|
+
android,
|
|
72
|
+
web
|
|
73
|
+
}
|
|
74
|
+
};
|
|
75
|
+
}
|
|
76
|
+
async function resolvePlatformInfo(platform, runtime, deps, state) {
|
|
77
|
+
const { urlCreator, getAppId } = deps;
|
|
78
|
+
const { isDevClient, isRedirectPageEnabled } = state;
|
|
79
|
+
const appId = await getAppId(platform);
|
|
80
|
+
if (platform === 'web') {
|
|
81
|
+
// constructUrl inherits the tunnel host from `defaults.hostType` when --tunnel is active,
|
|
82
|
+
// so this returns the ngrok URL instead of localhost in that case.
|
|
83
|
+
return {
|
|
84
|
+
runtime: 'web',
|
|
85
|
+
url: urlCreator.constructUrl({
|
|
86
|
+
scheme: 'http'
|
|
87
|
+
}),
|
|
88
|
+
appId
|
|
89
|
+
};
|
|
90
|
+
}
|
|
91
|
+
// Caller explicitly wants the disambiguation page — useful when they want the device (not the
|
|
92
|
+
// dev server) to pick between Expo Go and the dev build. No `runtime` field on the response
|
|
93
|
+
// since the actual runtime depends on the device's choice.
|
|
94
|
+
if (runtime === 'unknown') {
|
|
95
|
+
return {
|
|
96
|
+
url: urlCreator.constructLoadingUrl({}, platform),
|
|
97
|
+
appId
|
|
98
|
+
};
|
|
99
|
+
}
|
|
100
|
+
// `runtime: 'default'` mirrors what pressing `i` / `a` does in the terminal:
|
|
101
|
+
// --dev-client server → open the dev client directly.
|
|
102
|
+
// project has both → hand off to the disambiguation interstitial so the
|
|
103
|
+
// device resolves between Expo Go and the dev build.
|
|
104
|
+
// else → open Expo Go directly.
|
|
105
|
+
if (runtime === 'default') {
|
|
106
|
+
if (isDevClient) {
|
|
107
|
+
return {
|
|
108
|
+
runtime: 'custom',
|
|
109
|
+
url: urlCreator.constructDevClientUrl(),
|
|
110
|
+
appId
|
|
111
|
+
};
|
|
112
|
+
}
|
|
113
|
+
if (isRedirectPageEnabled) {
|
|
114
|
+
return {
|
|
115
|
+
url: urlCreator.constructLoadingUrl({}, platform),
|
|
116
|
+
appId
|
|
117
|
+
};
|
|
118
|
+
}
|
|
119
|
+
return {
|
|
120
|
+
runtime: 'expo',
|
|
121
|
+
url: urlCreator.constructUrl({
|
|
122
|
+
scheme: 'exp'
|
|
123
|
+
}),
|
|
124
|
+
appId
|
|
125
|
+
};
|
|
126
|
+
}
|
|
127
|
+
return {
|
|
128
|
+
runtime,
|
|
129
|
+
url: runtime === 'custom' ? urlCreator.constructDevClientUrl() : urlCreator.constructUrl({
|
|
130
|
+
scheme: 'exp'
|
|
131
|
+
}),
|
|
132
|
+
appId
|
|
133
|
+
};
|
|
134
|
+
}
|
|
135
|
+
function createOpen(deps) {
|
|
136
|
+
return async ({ platform })=>{
|
|
137
|
+
if (platform === 'web') {
|
|
138
|
+
const result = await deps.openPlatformAsync('desktop');
|
|
139
|
+
return {
|
|
140
|
+
platform,
|
|
141
|
+
runtime: 'web',
|
|
142
|
+
url: result.url ?? ''
|
|
143
|
+
};
|
|
144
|
+
}
|
|
145
|
+
const launchTarget = platform === 'ios' ? 'simulator' : 'emulator';
|
|
146
|
+
const result = await deps.openPlatformAsync(launchTarget, {
|
|
147
|
+
shouldPrompt: false
|
|
148
|
+
});
|
|
149
|
+
return {
|
|
150
|
+
platform,
|
|
151
|
+
runtime: deps.getIsDevClient() ? 'custom' : 'expo',
|
|
152
|
+
url: result.url ?? ''
|
|
153
|
+
};
|
|
154
|
+
};
|
|
155
|
+
}
|
|
156
|
+
|
|
157
|
+
//# sourceMappingURL=openHandlers.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"sources":["../../../../../src/start/server/middleware/openHandlers.ts"],"sourcesContent":["import type {\n OpenActionResult,\n OpenInfoResult,\n OpenMiddlewareOptions,\n OpenNativeRuntime,\n OpenPlatform,\n OpenPlatformInfo,\n OpenRequestedRuntime,\n} from './OpenMiddleware';\nimport type { UrlCreator } from '../UrlCreator';\n\ninterface InfoHandlerDeps {\n /** Stable UrlCreator instance — its `defaults` mutate when `toggleRuntimeMode` runs, so the same instance keeps producing fresh URLs and reflects the current scheme. */\n urlCreator: UrlCreator;\n /**\n * Read live values every call. The dev server's runtime mode can flip mid-run via the `s` key\n * in the terminal, and `expo-dev-client` can be installed while the server is running — both\n * change `isDevClient` and `isRedirectPageEnabled`, and the endpoint should reflect the\n * current state on every request.\n */\n getIsDevClient: () => boolean;\n /** Live mirror of `BundlerDevServer.isRedirectPageEnabled()`. */\n getIsRedirectPageEnabled: () => boolean;\n /**\n * Resolve the native application identifier for a platform (iOS bundle id / Android package\n * name). Implementations should return `null` instead of throwing when the project has no\n * configured identifier; the endpoint surfaces `null` so distributed preview systems can detect\n * that the build can't be matched by app id and either bail out or prompt the user.\n */\n getAppId: (platform: OpenPlatform) => Promise<string | null>;\n}\n\n/**\n * Build the GET handler for `/_expo/open`. Resolves dry-run info for a single platform, or for\n * every platform in discovery mode. Extracted so it can be exercised with a real\n * {@link UrlCreator} in tests (covers tunnel routing in particular).\n */\nexport function createInfoHandler(deps: InfoHandlerDeps): OpenMiddlewareOptions['getInfo'] {\n return ({ platform, runtime }) => resolveOpenInfo({ platform, runtime }, deps);\n}\n\nexport async function resolveOpenInfo(\n { platform, runtime }: { platform: OpenPlatform | null; runtime: OpenRequestedRuntime },\n deps: InfoHandlerDeps\n): Promise<OpenInfoResult> {\n // Snapshot the live state once per request so the response is internally consistent even if a\n // toggle happens between sub-resolutions.\n const scheme = deps.urlCreator.getScheme();\n const isDevClient = deps.getIsDevClient();\n const isRedirectPageEnabled = deps.getIsRedirectPageEnabled();\n const availableRuntimes: OpenNativeRuntime[] = isDevClient\n ? ['custom']\n : isRedirectPageEnabled\n ? ['expo', 'custom']\n : ['expo'];\n\n if (platform) {\n return {\n scheme,\n availableRuntimes,\n ...(await resolvePlatformInfo(platform, runtime, deps, {\n isDevClient,\n isRedirectPageEnabled,\n })),\n };\n }\n\n const [ios, android, web] = await Promise.all([\n resolvePlatformInfo('ios', runtime, deps, { isDevClient, isRedirectPageEnabled }),\n resolvePlatformInfo('android', runtime, deps, { isDevClient, isRedirectPageEnabled }),\n resolvePlatformInfo('web', runtime, deps, { isDevClient, isRedirectPageEnabled }),\n ]);\n return { scheme, availableRuntimes, platforms: { ios, android, web } };\n}\n\nasync function resolvePlatformInfo(\n platform: OpenPlatform,\n runtime: OpenRequestedRuntime,\n deps: InfoHandlerDeps,\n state: { isDevClient: boolean; isRedirectPageEnabled: boolean }\n): Promise<OpenPlatformInfo> {\n const { urlCreator, getAppId } = deps;\n const { isDevClient, isRedirectPageEnabled } = state;\n const appId = await getAppId(platform);\n\n if (platform === 'web') {\n // constructUrl inherits the tunnel host from `defaults.hostType` when --tunnel is active,\n // so this returns the ngrok URL instead of localhost in that case.\n return { runtime: 'web', url: urlCreator.constructUrl({ scheme: 'http' }), appId };\n }\n\n // Caller explicitly wants the disambiguation page — useful when they want the device (not the\n // dev server) to pick between Expo Go and the dev build. No `runtime` field on the response\n // since the actual runtime depends on the device's choice.\n if (runtime === 'unknown') {\n return { url: urlCreator.constructLoadingUrl({}, platform), appId };\n }\n\n // `runtime: 'default'` mirrors what pressing `i` / `a` does in the terminal:\n // --dev-client server → open the dev client directly.\n // project has both → hand off to the disambiguation interstitial so the\n // device resolves between Expo Go and the dev build.\n // else → open Expo Go directly.\n if (runtime === 'default') {\n if (isDevClient) {\n return { runtime: 'custom', url: urlCreator.constructDevClientUrl(), appId };\n }\n if (isRedirectPageEnabled) {\n return { url: urlCreator.constructLoadingUrl({}, platform), appId };\n }\n return { runtime: 'expo', url: urlCreator.constructUrl({ scheme: 'exp' }), appId };\n }\n\n return {\n runtime,\n url:\n runtime === 'custom'\n ? urlCreator.constructDevClientUrl()\n : urlCreator.constructUrl({ scheme: 'exp' }),\n appId,\n };\n}\n\ninterface OpenHandlerDeps {\n /** Live `BundlerDevServer.isDevClient` — `s` in the terminal can flip this between dispatch and response. */\n getIsDevClient: () => boolean;\n /** Same shape as `BundlerDevServer.openPlatformAsync`. */\n openPlatformAsync: (\n launchTarget: 'simulator' | 'emulator' | 'desktop',\n resolver?: { shouldPrompt?: boolean }\n ) => Promise<{ url: string | null }>;\n}\n\n/** Build the POST handler for `/_expo/open` — dispatches to the dev server's platform launcher. */\nexport function createOpen(deps: OpenHandlerDeps): OpenMiddlewareOptions['open'] {\n return async ({ platform }): Promise<OpenActionResult> => {\n if (platform === 'web') {\n const result = await deps.openPlatformAsync('desktop');\n return { platform, runtime: 'web', url: result.url ?? '' };\n }\n const launchTarget = platform === 'ios' ? 'simulator' : 'emulator';\n const result = await deps.openPlatformAsync(launchTarget, { shouldPrompt: false });\n return {\n platform,\n runtime: deps.getIsDevClient() ? 'custom' : 'expo',\n url: result.url ?? '',\n };\n };\n}\n"],"names":["createInfoHandler","createOpen","resolveOpenInfo","deps","platform","runtime","scheme","urlCreator","getScheme","isDevClient","getIsDevClient","isRedirectPageEnabled","getIsRedirectPageEnabled","availableRuntimes","resolvePlatformInfo","ios","android","web","Promise","all","platforms","state","getAppId","appId","url","constructUrl","constructLoadingUrl","constructDevClientUrl","result","openPlatformAsync","launchTarget","shouldPrompt"],"mappings":";;;;;;;;;;;QAqCgBA;eAAAA;;QAiGAC;eAAAA;;QA7FMC;eAAAA;;;AAJf,SAASF,kBAAkBG,IAAqB;IACrD,OAAO,CAAC,EAAEC,QAAQ,EAAEC,OAAO,EAAE,GAAKH,gBAAgB;YAAEE;YAAUC;QAAQ,GAAGF;AAC3E;AAEO,eAAeD,gBACpB,EAAEE,QAAQ,EAAEC,OAAO,EAAoE,EACvFF,IAAqB;IAErB,8FAA8F;IAC9F,0CAA0C;IAC1C,MAAMG,SAASH,KAAKI,UAAU,CAACC,SAAS;IACxC,MAAMC,cAAcN,KAAKO,cAAc;IACvC,MAAMC,wBAAwBR,KAAKS,wBA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,SAAS;gBAAUmB,KAAKjB,WAAWoB,qBAAqB;gBAAIJ;YAAM;QAC7E;QACA,IAAIZ,uBAAuB;YACzB,OAAO;gBAAEa,KAAKjB,WAAWmB,mBAAmB,CAAC,CAAC,GAAGtB;gBAAWmB;YAAM;QACpE;QACA,OAAO;YAAElB,SAAS;YAAQmB,KAAKjB,WAAWkB,YAAY,CAAC;gBAAEnB,QAAQ;YAAM;YAAIiB;QAAM;IACnF;IAEA,OAAO;QACLlB;QACAmB,KACEnB,YAAY,WACRE,WAAWoB,qBAAqB,KAChCpB,WAAWkB,YAAY,CAAC;YAAEnB,QAAQ;QAAM;QAC9CiB;IACF;AACF;AAaO,SAAStB,WAAWE,IAAqB;IAC9C,OAAO,OAAO,EAAEC,QAAQ,EAAE;QACxB,IAAIA,aAAa,OAAO;YACtB,MAAMwB,SAAS,MAAMzB,KAAK0B,iBAAiB,CAAC;YAC5C,OAAO;gBAAEzB;gBAAUC,SAAS;gBAAOmB,KAAKI,OAAOJ,GAAG,IAAI;YAAG;QAC3D;QACA,MAAMM,eAAe1B,aAAa,QAAQ,cAAc;QACxD,MAAMwB,SAAS,MAAMzB,KAAK0B,iBAAiB,CAACC,cAAc;YAAEC,cAAc;QAAM;QAChF,OAAO;YACL3B;YACAC,SAASF,KAAKO,cAAc,KAAK,WAAW;YAC5Cc,KAAKI,OAAOJ,GAAG,IAAI;QACrB;IACF;AACF"}
|
|
@@ -39,7 +39,7 @@ function _path() {
|
|
|
39
39
|
}
|
|
40
40
|
const _templates = require("../../customize/templates");
|
|
41
41
|
const _html = require("../../export/html");
|
|
42
|
-
const
|
|
42
|
+
const _publicFolder = require("../../export/publicFolder");
|
|
43
43
|
function _interop_require_default(obj) {
|
|
44
44
|
return obj && obj.__esModule ? obj : {
|
|
45
45
|
default: obj
|
|
@@ -58,8 +58,8 @@ async function createTemplateHtmlFromExpoConfigAsync(projectRoot, { scripts, css
|
|
|
58
58
|
themeColor: (_exp_web2 = exp.web) == null ? void 0 : _exp_web2.themeColor
|
|
59
59
|
});
|
|
60
60
|
}
|
|
61
|
-
function getFileFromLocalPublicFolder(projectRoot, {
|
|
62
|
-
const localFilePath = _path().default.resolve(
|
|
61
|
+
function getFileFromLocalPublicFolder(projectRoot, { filePath }) {
|
|
62
|
+
const localFilePath = _path().default.resolve((0, _publicFolder.getPublicFolderPath)(projectRoot), filePath);
|
|
63
63
|
if (!_fs().default.existsSync(localFilePath)) {
|
|
64
64
|
return null;
|
|
65
65
|
}
|
|
@@ -67,8 +67,6 @@ function getFileFromLocalPublicFolder(projectRoot, { publicFolder, filePath }) {
|
|
|
67
67
|
}
|
|
68
68
|
/** Attempt to read the `index.html` from the local project before falling back on the template `index.html`. */ async function getTemplateIndexHtmlAsync(projectRoot) {
|
|
69
69
|
let filePath = getFileFromLocalPublicFolder(projectRoot, {
|
|
70
|
-
// TODO: Maybe use the app.json override.
|
|
71
|
-
publicFolder: _env.env.EXPO_PUBLIC_FOLDER,
|
|
72
70
|
filePath: 'index.html'
|
|
73
71
|
});
|
|
74
72
|
if (!filePath) {
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"sources":["../../../../src/start/server/webTemplate.ts"],"sourcesContent":["import type { ExpoConfig } from '@expo/config';\nimport { getConfig, getNameFromConfig } from '@expo/config';\nimport fs from 'fs';\nimport path from 'path';\n\nimport { TEMPLATES } from '../../customize/templates';\nimport { appendLinkToHtml, appendScriptsToHtml } from '../../export/html';\nimport {
|
|
1
|
+
{"version":3,"sources":["../../../../src/start/server/webTemplate.ts"],"sourcesContent":["import type { ExpoConfig } from '@expo/config';\nimport { getConfig, getNameFromConfig } from '@expo/config';\nimport fs from 'fs';\nimport path from 'path';\n\nimport { TEMPLATES } from '../../customize/templates';\nimport { appendLinkToHtml, appendScriptsToHtml } from '../../export/html';\nimport { getPublicFolderPath } from '../../export/publicFolder';\n\n/**\n * Create a static HTML for SPA styled websites.\n * This method attempts to reuse the same patterns as `@expo/webpack-config`.\n */\nexport async function createTemplateHtmlFromExpoConfigAsync(\n projectRoot: string,\n {\n scripts,\n cssLinks,\n exp = getConfig(projectRoot, { skipSDKVersionRequirement: true }).exp,\n }: {\n scripts: string[];\n cssLinks?: string[];\n exp?: ExpoConfig;\n }\n) {\n return createTemplateHtmlAsync(projectRoot, {\n langIsoCode: exp.web?.lang ?? 'en',\n scripts,\n cssLinks,\n title: getNameFromConfig(exp).webName ?? 'Expo App',\n description: exp.web?.description,\n themeColor: exp.web?.themeColor,\n });\n}\n\nfunction getFileFromLocalPublicFolder(\n projectRoot: string,\n { filePath }: { filePath: string }\n): string | null {\n const localFilePath = path.resolve(getPublicFolderPath(projectRoot), filePath);\n if (!fs.existsSync(localFilePath)) {\n return null;\n }\n return localFilePath;\n}\n\n/** Attempt to read the `index.html` from the local project before falling back on the template `index.html`. */\nasync function getTemplateIndexHtmlAsync(projectRoot: string): Promise<string> {\n let filePath = getFileFromLocalPublicFolder(projectRoot, {\n filePath: 'index.html',\n });\n if (!filePath) {\n filePath = TEMPLATES.find((value) => value.id === 'index.html')!.file(projectRoot);\n }\n return fs.promises.readFile(filePath, 'utf8');\n}\n\n/** Return an `index.html` string with template values added. */\nexport async function createTemplateHtmlAsync(\n projectRoot: string,\n {\n scripts,\n cssLinks,\n description,\n langIsoCode,\n title,\n themeColor,\n }: {\n scripts: string[];\n cssLinks?: string[];\n description?: string;\n langIsoCode: string;\n title: string;\n themeColor?: string;\n }\n): Promise<string> {\n // Resolve the best possible index.html template file.\n let contents = await getTemplateIndexHtmlAsync(projectRoot);\n\n contents = contents.replace('%LANG_ISO_CODE%', langIsoCode);\n contents = contents.replace('%WEB_TITLE%', title);\n\n contents = appendScriptsToHtml(contents, scripts);\n\n if (cssLinks) {\n contents = appendLinkToHtml(\n contents,\n cssLinks\n .map((href) => [\n // NOTE: We probably don't have to preload the CSS files for SPA-styled websites.\n {\n as: 'style',\n rel: 'preload',\n href,\n },\n {\n rel: 'stylesheet',\n href,\n },\n ])\n .flat()\n );\n }\n\n if (themeColor) {\n contents = addMeta(contents, `name=\"theme-color\" content=\"${themeColor}\"`);\n }\n\n if (description) {\n contents = addMeta(contents, `name=\"description\" content=\"${description}\"`);\n }\n\n return contents;\n}\n\n/** Add a `<meta />` tag to the `<head />` element. */\nfunction addMeta(contents: string, meta: string): string {\n return contents.replace('</head>', `<meta ${meta}>\\n</head>`);\n}\n"],"names":["createTemplateHtmlAsync","createTemplateHtmlFromExpoConfigAsync","projectRoot","scripts","cssLinks","exp","getConfig","skipSDKVersionRequirement","langIsoCode","web","lang","title","getNameFromConfig","webName","description","themeColor","getFileFromLocalPublicFolder","filePath","localFilePath","path","resolve","getPublicFolderPath","fs","existsSync","getTemplateIndexHtmlAsync","TEMPLATES","find","value","id","file","promises","readFile","contents","replace","appendScriptsToHtml","appendLinkToHtml","map","href","as","rel","flat","addMeta","meta"],"mappings":";;;;;;;;;;;QA0DsBA;eAAAA;;QA7CAC;eAAAA;;;;yBAZuB;;;;;;;gEAC9B;;;;;;;gEACE;;;;;;2BAES;sBAC4B;8BAClB;;;;;;AAM7B,eAAeA,sCACpBC,WAAmB,EACnB,EACEC,OAAO,EACPC,QAAQ,EACRC,MAAMC,IAAAA,mBAAS,EAACJ,aAAa;IAAEK,2BAA2B;AAAK,GAAGF,GAAG,EAKtE;QAGcA,UAIAA,WACDA;IANd,OAAOL,wBAAwBE,aAAa;QAC1CM,aAAaH,EAAAA,WAAAA,IAAII,GAAG,qBAAPJ,SAASK,IAAI,KAAI;QAC9BP;QACAC;QACAO,OAAOC,IAAAA,2BAAiB,EAACP,KAAKQ,OAAO,IAAI;QACzCC,WAAW,GAAET,YAAAA,IAAII,GAAG,qBAAPJ,UAASS,WAAW;QACjCC,UAAU,GAAEV,YAAAA,IAAII,GAAG,qBAAPJ,UAASU,UAAU;IACjC;AACF;AAEA,SAASC,6BACPd,WAAmB,EACnB,EAAEe,QAAQ,EAAwB;IAElC,MAAMC,gBAAgBC,eAAI,CAACC,OAAO,CAACC,IAAAA,iCAAmB,EAACnB,cAA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AC9D"}
|
package/build/src/utils/net.js
CHANGED
|
@@ -35,7 +35,13 @@ const isMatchingOrigin = (request, serverBaseUrl)=>{
|
|
|
35
35
|
if (!request.headers.origin) {
|
|
36
36
|
return true;
|
|
37
37
|
}
|
|
38
|
-
|
|
38
|
+
let actualHost;
|
|
39
|
+
try {
|
|
40
|
+
actualHost = new URL(`${request.headers.origin}`).host;
|
|
41
|
+
} catch {
|
|
42
|
+
// Malformed Origin — treat as untrusted.
|
|
43
|
+
return false;
|
|
44
|
+
}
|
|
39
45
|
const expectedHost = new URL(serverBaseUrl).host;
|
|
40
46
|
return actualHost === expectedHost;
|
|
41
47
|
};
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"sources":["../../../src/utils/net.ts"],"sourcesContent":["import type { IncomingHttpHeaders } from 'node:http';\nimport type { Socket } from 'node:net';\n\nconst ipv6To4Prefix = '::ffff:';\n\nexport const isLocalSocket = (socket: Socket): boolean => {\n let { localAddress, remoteAddress, remoteFamily } = socket;\n\n const isLoopbackRequest = localAddress && localAddress === remoteAddress;\n if (isLoopbackRequest) {\n return true;\n } else if (!remoteAddress || !remoteFamily) {\n return false;\n }\n\n if (remoteFamily === 'IPv6' && remoteAddress.startsWith(ipv6To4Prefix)) {\n remoteAddress = remoteAddress.slice(ipv6To4Prefix.length);\n }\n\n return remoteAddress === '::1' || remoteAddress.startsWith('127.');\n};\n\ninterface AbstractIncomingMessage {\n headers: IncomingHttpHeaders | Record<string, string | string[]>;\n}\n\nexport const isMatchingOrigin = (\n request: AbstractIncomingMessage,\n serverBaseUrl: string\n): boolean => {\n // NOTE(@kitten): The browser will always send an origin header for websocket upgrade connections\n if (!request.headers.origin) {\n return true;\n }\n
|
|
1
|
+
{"version":3,"sources":["../../../src/utils/net.ts"],"sourcesContent":["import type { IncomingHttpHeaders } from 'node:http';\nimport type { Socket } from 'node:net';\n\nconst ipv6To4Prefix = '::ffff:';\n\nexport const isLocalSocket = (socket: Socket): boolean => {\n let { localAddress, remoteAddress, remoteFamily } = socket;\n\n const isLoopbackRequest = localAddress && localAddress === remoteAddress;\n if (isLoopbackRequest) {\n return true;\n } else if (!remoteAddress || !remoteFamily) {\n return false;\n }\n\n if (remoteFamily === 'IPv6' && remoteAddress.startsWith(ipv6To4Prefix)) {\n remoteAddress = remoteAddress.slice(ipv6To4Prefix.length);\n }\n\n return remoteAddress === '::1' || remoteAddress.startsWith('127.');\n};\n\ninterface AbstractIncomingMessage {\n headers: IncomingHttpHeaders | Record<string, string | string[]>;\n}\n\nexport const isMatchingOrigin = (\n request: AbstractIncomingMessage,\n serverBaseUrl: string\n): boolean => {\n // NOTE(@kitten): The browser will always send an origin header for websocket upgrade connections\n if (!request.headers.origin) {\n return true;\n }\n let actualHost: string;\n try {\n actualHost = new URL(`${request.headers.origin}`).host;\n } catch {\n // Malformed Origin — treat as untrusted.\n return false;\n }\n const expectedHost = new URL(serverBaseUrl).host;\n return actualHost === expectedHost;\n};\n"],"names":["isLocalSocket","isMatchingOrigin","ipv6To4Prefix","socket","localAddress","remoteAddress","remoteFamily","isLoopbackRequest","startsWith","slice","length","request","serverBaseUrl","headers","origin","actualHost","URL","host","expectedHost"],"mappings":";;;;;;;;;;;QAKaA;eAAAA;;QAqBAC;eAAAA;;;AAvBb,MAAMC,gBAAgB;AAEf,MAAMF,gBAAgB,CAACG;IAC5B,IAAI,EAAEC,YAAY,EAAEC,aAAa,EAAEC,YAAY,EAAE,GAAGH;IAEpD,MAAMI,oBAAoBH,gBAAgBA,iBAAiBC;IAC3D,IAAIE,mBAAmB;QACrB,OAAO;IACT,OAAO,IAAI,CAACF,iBAAiB,CAACC,cAAc;QAC1C,OAAO;IACT;IAEA,IAAIA,iBAAiB,UAAUD,cAAcG,UAAU,CAACN,gBAAgB;QACtEG,gBAAgBA,cAAcI,KAAK,CAACP,cAAcQ,MAAM;IAC1D;IAEA,OAAOL,kBAAkB,SAASA,cAAcG,UAAU,CAAC;AAC7D;AAMO,MAAMP,mBAAmB,CAC9BU,SACAC;IAEA,iGAAiG;IACjG,IAAI,CAACD,QAAQE,OAAO,CAACC,MAAM,EAAE;QAC3B,OAAO;IACT;IACA,IAAIC;IACJ,IAAI;QACFA,aAAa,IAAIC,IAAI,GAAGL,QAAQE,OAAO,CAACC,MAAM,EAAE,EAAEG,IAAI;IACxD,EAAE,OAAM;QACN,yCAAyC;QACzC,OAAO;IACT;IACA,MAAMC,eAAe,IAAIF,IAAIJ,eAAeK,IAAI;IAChD,OAAOF,eAAeG;AACxB"}
|
package/build/src/utils/tar.js
CHANGED
|
@@ -71,8 +71,8 @@ class ChecksumStream extends TransformStream {
|
|
|
71
71
|
return this.hash.digest(encoding);
|
|
72
72
|
}
|
|
73
73
|
}
|
|
74
|
-
async function extractStream(input,
|
|
75
|
-
output = _nodepath().default.resolve(
|
|
74
|
+
async function extractStream(input, targetOutput, options = {}) {
|
|
75
|
+
const output = _nodepath().default.resolve(targetOutput) + _nodepath().default.sep;
|
|
76
76
|
await _nodefs().default.promises.mkdir(output, {
|
|
77
77
|
recursive: true
|
|
78
78
|
});
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"sources":["../../../src/utils/tar.ts"],"sourcesContent":["import { streamToAsyncIterable, TarTypeFlag, untar } from 'multitars';\nimport crypto from 'node:crypto';\nimport fs from 'node:fs';\nimport path from 'node:path';\nimport { Readable } from 'node:stream';\n\nconst debug = require('debug')('expo:utils:tar') as typeof console.log;\n\nclass ChecksumStream extends TransformStream {\n hash: crypto.Hash;\n constructor(algorithm: string) {\n super({\n transform: (chunk, controller) => {\n this.hash.update(chunk);\n controller.enqueue(chunk);\n },\n });\n this.hash = crypto.createHash(algorithm);\n }\n\n digest(): Buffer;\n digest(encoding: crypto.BinaryToTextEncoding): string;\n digest(encoding?: crypto.BinaryToTextEncoding): string | Buffer {\n return this.hash.digest(encoding!);\n }\n}\n\nexport interface ExtractOptions {\n strip?: number;\n filter?(name: string, type: TarTypeFlag): boolean | null | undefined;\n rename?(name: string, type: TarTypeFlag): string | null | undefined;\n checksumAlgorithm?: string;\n}\n\nexport async function extractStream(\n input: ReadableStream,\n
|
|
1
|
+
{"version":3,"sources":["../../../src/utils/tar.ts"],"sourcesContent":["import { streamToAsyncIterable, TarTypeFlag, untar } from 'multitars';\nimport crypto from 'node:crypto';\nimport fs from 'node:fs';\nimport path from 'node:path';\nimport { Readable } from 'node:stream';\n\nconst debug = require('debug')('expo:utils:tar') as typeof console.log;\n\nclass ChecksumStream extends TransformStream {\n hash: crypto.Hash;\n constructor(algorithm: string) {\n super({\n transform: (chunk, controller) => {\n this.hash.update(chunk);\n controller.enqueue(chunk);\n },\n });\n this.hash = crypto.createHash(algorithm);\n }\n\n digest(): Buffer;\n digest(encoding: crypto.BinaryToTextEncoding): string;\n digest(encoding?: crypto.BinaryToTextEncoding): string | Buffer {\n return this.hash.digest(encoding!);\n }\n}\n\nexport interface ExtractOptions {\n strip?: number;\n filter?(name: string, type: TarTypeFlag): boolean | null | undefined;\n rename?(name: string, type: TarTypeFlag): string | null | undefined;\n checksumAlgorithm?: string;\n}\n\nexport async function extractStream(\n input: ReadableStream,\n targetOutput: string,\n options: ExtractOptions = {}\n): Promise<string> {\n const output = path.resolve(targetOutput) + path.sep;\n await fs.promises.mkdir(output, { recursive: true });\n\n const { checksumAlgorithm, strip = 0, rename, filter } = options;\n\n const checksumStream = new ChecksumStream(checksumAlgorithm || 'md5');\n const decompressionStream = new DecompressionStream('gzip');\n\n const body = input.pipeThrough(checksumStream).pipeThrough(decompressionStream);\n\n for await (const file of untar(body)) {\n let name = path.normalize(file.name);\n if (filter && !filter(name, file.typeflag)) {\n debug(`filtered: ${path.resolve(output, name)}`);\n continue;\n } else if (rename) {\n name = rename(name, file.typeflag) ?? name;\n }\n\n for (let idx = 0; idx < strip; idx++) {\n const sepIdx = name.indexOf(path.sep);\n if (sepIdx > -1) {\n name = name.slice(sepIdx + 1);\n } else {\n break;\n }\n }\n\n const resolved = path.resolve(output, name);\n if (!resolved.startsWith(output)) {\n debug(`skip: ${resolved}`);\n continue;\n }\n\n const parent = path.dirname(resolved);\n if (parent !== output) {\n let exists = false;\n try {\n const stat = await fs.promises.lstat(parent);\n if (stat.isSymbolicLink() || (!stat.isDirectory() && !stat.isFile())) {\n debug(`skip: ${resolved}`);\n continue;\n } else if (stat.isDirectory()) {\n exists = true;\n }\n } catch {}\n\n if (!exists) {\n debug(`mkdir(p): ${parent}`);\n await fs.promises.mkdir(parent, { recursive: true });\n }\n }\n\n switch (file.typeflag) {\n case TarTypeFlag.FILE:\n debug(`write(${file.mode.toString(8)}): ${resolved}`);\n await fs.promises.writeFile(resolved, streamToAsyncIterable(file.stream()), {\n mode: file.mode,\n });\n break;\n case TarTypeFlag.DIRECTORY:\n debug(`mkdir(${file.mode.toString(8)}): ${resolved}`);\n try {\n await fs.promises.mkdir(resolved, { mode: file.mode });\n } catch (error: any) {\n if (error.code !== 'EEXIST') {\n throw error;\n }\n }\n break;\n case TarTypeFlag.SYMLINK:\n case TarTypeFlag.LINK: {\n const target = path.resolve(parent, file.linkname ?? '');\n if (!target.startsWith(output) || target === parent) {\n debug(`skip: ${resolved} -> ${target}`);\n continue;\n }\n\n if (file.typeflag === TarTypeFlag.LINK) {\n debug(`link: ${resolved} -> ${target}`);\n await fs.promises.link(target, resolved);\n } else {\n const stat = await fs.promises.lstat(target).catch(() => null);\n const type = stat?.isDirectory() ? 'dir' : 'file';\n debug(`symlink(${type}): ${resolved} -> ${target}`);\n await fs.promises.symlink(target, resolved, type);\n }\n break;\n }\n }\n }\n\n return checksumStream.digest('hex');\n}\n\n/** Extract a tar using built-in tools if available and falling back on Node.js. */\nexport async function extractAsync(\n input: string,\n output: string,\n options?: ExtractOptions\n): Promise<void> {\n await extractStream(\n Readable.toWeb(fs.createReadStream(input)) as ReadableStream,\n output,\n options\n );\n}\n"],"names":["extractAsync","extractStream","debug","require","ChecksumStream","TransformStream","algorithm","transform","chunk","controller","hash","update","enqueue","crypto","createHash","digest","encoding","input","targetOutput","options","output","path","resolve","sep","fs","promises","mkdir","recursive","checksumAlgorithm","strip","rename","filter","checksumStream","decompressionStream","DecompressionStream","body","pipeThrough","file","untar","name","normalize","typeflag","idx","sepIdx","indexOf","slice","resolved","startsWith","parent","dirname","exists","stat","lstat","isSymbolicLink","isDirectory","isFile","TarTypeFlag","FILE","mode","toString","writeFile","streamToAsyncIterable","stream","DIRECTORY","error","code","SYMLINK","LINK","target","linkname","link","catch","type","symlink","Readable","toWeb","createReadStream"],"mappings":";;;;;;;;;;;QAuIsBA;eAAAA;;QArGAC;eAAAA;;;;yBAlCoC;;;;;;;gEACvC;;;;;;;gEACJ;;;;;;;gEACE;;;;;;;yBACQ;;;;;;;;;;;AAEzB,MAAMC,QAAQC,QAAQ,SAAS;AAE/B,MAAMC,uBAAuBC;IAE3B,YAAYC,SAAiB,CAAE;QAC7B,KAAK,CAAC;YACJC,WAAW,CAACC,OAAOC;gBACjB,IAAI,CAACC,IAAI,CAACC,MAAM,CAACH;gBACjBC,WAAWG,OAAO,CAACJ;YACrB;QACF;QACA,IAAI,CAACE,IAAI,GAAGG,qBAAM,CAACC,UAAU,CAACR;IAChC;IAIAS,OAAOC,QAAsC,EAAmB;QAC9D,OAAO,IAAI,CAACN,IAAI,CAACK,MAAM,CAACC;IAC1B;AACF;AASO,eAAef,cACpBgB,KAAqB,EACrBC,YAAoB,EACpBC,UAA0B,CAAC,CAAC;IAE5B,MAAMC,SAASC,mBAAI,CAACC,OAAO,CAACJ,gBAAgBG,mBAAI,CAACE,GAAG;IACpD,MAAMC,iBAAE,CAACC,QAAQ,CAACC,KAAK,CAACN,QAAQ;QAAEO,WAAW;IAAK;IAElD,MAAM,EAAEC,iBAAiB,EAAEC,QAAQ,CAAC,EAAEC,MAAM,EAAEC,MAAM,EAAE,GAAGZ;IAEzD,MAAMa,iBAAiB,IAAI5B,eAAewB,qBAAqB;IAC/D,MAAMK,sBAAsB,IAAIC,oBAAoB;IAEpD,MAAMC,OAAOlB,MAAMmB,WAAW,CAACJ,gBAAg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,QAAQ,CAAC2B,KAAK,CAACgB,QAAQG,KAAK,CAAC,IAAM;wBACzD,MAAMC,OAAOrB,CAAAA,wBAAAA,KAAMG,WAAW,MAAK,QAAQ;wBAC3CpD,MAAM,CAAC,QAAQ,EAAEsE,KAAK,GAAG,EAAE1B,SAAS,IAAI,EAAEsB,QAAQ;wBAClD,MAAM5C,iBAAE,CAACC,QAAQ,CAACgD,OAAO,CAACL,QAAQtB,UAAU0B;oBAC9C;oBACA;gBACF;QACF;IACF;IAEA,OAAOxC,eAAejB,MAAM,CAAC;AAC/B;AAGO,eAAef,aACpBiB,KAAa,EACbG,MAAc,EACdD,OAAwB;IAExB,MAAMlB,cACJyE,sBAAQ,CAACC,KAAK,CAACnD,iBAAE,CAACoD,gBAAgB,CAAC3D,SACnCG,QACAD;AAEJ"}
|
|
@@ -26,7 +26,7 @@ class FetchClient {
|
|
|
26
26
|
this.headers = {
|
|
27
27
|
accept: 'application/json',
|
|
28
28
|
'content-type': 'application/json',
|
|
29
|
-
'user-agent': `expo-cli/${"56.1.
|
|
29
|
+
'user-agent': `expo-cli/${"56.1.6"}`,
|
|
30
30
|
authorization: 'Basic ' + _nodebuffer().Buffer.from(`${target}:`).toString('base64')
|
|
31
31
|
};
|
|
32
32
|
}
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@expo/cli",
|
|
3
|
-
"version": "56.1.
|
|
3
|
+
"version": "56.1.6",
|
|
4
4
|
"description": "The Expo CLI",
|
|
5
5
|
"main": "main.js",
|
|
6
6
|
"bin": {
|
|
@@ -39,23 +39,23 @@
|
|
|
39
39
|
"homepage": "https://github.com/expo/expo/tree/main/packages/@expo/cli",
|
|
40
40
|
"dependencies": {
|
|
41
41
|
"@expo/code-signing-certificates": "^0.0.6",
|
|
42
|
-
"@expo/config": "~56.0.
|
|
43
|
-
"@expo/config-plugins": "~56.0.
|
|
42
|
+
"@expo/config": "~56.0.7",
|
|
43
|
+
"@expo/config-plugins": "~56.0.6",
|
|
44
44
|
"@expo/devcert": "^1.2.1",
|
|
45
45
|
"@expo/env": "~2.2.0",
|
|
46
46
|
"@expo/image-utils": "^0.9.3",
|
|
47
|
-
"@expo/inline-modules": "^0.0.
|
|
47
|
+
"@expo/inline-modules": "^0.0.8",
|
|
48
48
|
"@expo/json-file": "^10.1.0",
|
|
49
|
-
"@expo/log-box": "^56.0.
|
|
49
|
+
"@expo/log-box": "^56.0.11",
|
|
50
50
|
"@expo/metro": "~56.0.0",
|
|
51
|
-
"@expo/metro-config": "~56.0.
|
|
51
|
+
"@expo/metro-config": "~56.0.10",
|
|
52
52
|
"@expo/metro-file-map": "^56.0.3",
|
|
53
53
|
"@expo/osascript": "^2.5.0",
|
|
54
54
|
"@expo/package-manager": "^1.11.0",
|
|
55
55
|
"@expo/plist": "^0.6.0",
|
|
56
|
-
"@expo/prebuild-config": "^56.0.
|
|
56
|
+
"@expo/prebuild-config": "^56.0.9",
|
|
57
57
|
"@expo/require-utils": "^56.1.1",
|
|
58
|
-
"@expo/router-server": "^56.0.
|
|
58
|
+
"@expo/router-server": "^56.0.9",
|
|
59
59
|
"@expo/schema-utils": "^56.0.0",
|
|
60
60
|
"@expo/spawn-async": "^1.7.2",
|
|
61
61
|
"@expo/ws-tunnel": "^1.0.1",
|
|
@@ -71,7 +71,7 @@
|
|
|
71
71
|
"connect": "^3.7.0",
|
|
72
72
|
"debug": "^4.3.4",
|
|
73
73
|
"dnssd-advertise": "^1.1.4",
|
|
74
|
-
"expo-server": "^56.0.
|
|
74
|
+
"expo-server": "^56.0.3",
|
|
75
75
|
"fetch-nodeshim": "^0.4.10",
|
|
76
76
|
"getenv": "^2.0.0",
|
|
77
77
|
"glob": "^13.0.0",
|
|
@@ -156,13 +156,13 @@
|
|
|
156
156
|
"playwright": "^1.59.0",
|
|
157
157
|
"taskr": "^1.1.0",
|
|
158
158
|
"tree-kill": "^1.2.2",
|
|
159
|
-
"expo": "
|
|
160
|
-
"expo
|
|
159
|
+
"@expo/fingerprint": "0.18.3",
|
|
160
|
+
"expo": "56.0.0-preview.13",
|
|
161
|
+
"expo-router": "56.2.2",
|
|
161
162
|
"expo-module-scripts": "56.0.2",
|
|
162
|
-
"expo-
|
|
163
|
-
"@expo/fingerprint": "0.18.2"
|
|
163
|
+
"expo-modules-autolinking": "56.0.8"
|
|
164
164
|
},
|
|
165
|
-
"gitHead": "
|
|
165
|
+
"gitHead": "290368bc41026449a05a4ebf991b85c3a2fb0e3a",
|
|
166
166
|
"scripts": {
|
|
167
167
|
"build": "taskr",
|
|
168
168
|
"clean": "expo-module clean",
|