peachsim 0.1.2567 → 0.1.2569
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/cli/commands/login.ts +25 -3
- package/dist-lib/agent-daemon-client.cjs +1 -1
- package/dist-lib/agent-events.cjs +1 -1
- package/dist-lib/attached-projects.cjs +1 -1
- package/dist-lib/auth/shared-session.cjs +1 -1
- package/dist-lib/backend-origin.cjs +1 -1
- package/dist-lib/beta.cjs +1 -1
- package/dist-lib/beta.mjs +2 -2
- package/dist-lib/bridge-constants.cjs +1 -1
- package/dist-lib/bridge-contract-input.cjs +1 -1
- package/dist-lib/bridge-contract-input.mjs +5 -5
- package/dist-lib/bridge-contract.cjs +1 -1
- package/dist-lib/bridge-contract.mjs +3 -3
- package/dist-lib/bundle-channel.cjs +9 -9
- package/dist-lib/capture-contract.cjs +1 -1
- package/dist-lib/capture-contract.mjs +3 -3
- package/dist-lib/cloud-contract.cjs +1 -1
- package/dist-lib/cloud-contract.mjs +3 -3
- package/dist-lib/cloud-test-args.cjs +1 -1
- package/dist-lib/cloud-test-args.mjs +2 -2
- package/dist-lib/cloud.cjs +1 -1
- package/dist-lib/cloud.mjs +7 -7
- package/dist-lib/config.cjs +1 -1
- package/dist-lib/config.mjs +5 -5
- package/dist-lib/detox/index.cjs +2 -2
- package/dist-lib/dev-bundle-resolution.cjs +1 -1
- package/dist-lib/esm-chunks/{acorn-T7YHKKTA.mjs → acorn-GX23OCPZ.mjs} +3 -3
- package/dist-lib/esm-chunks/{chunk-D7JZ6LCH.mjs → chunk-6LJ5E7DT.mjs} +1 -1
- package/dist-lib/esm-chunks/{chunk-FRSQ7MNU.mjs → chunk-7YWKCVEU.mjs} +1 -1
- package/dist-lib/esm-chunks/{chunk-KFYRPGA7.mjs → chunk-AVHLCUS5.mjs} +1 -1
- package/dist-lib/esm-chunks/{chunk-CQF6QBF4.mjs → chunk-BBG63EGL.mjs} +5 -5
- package/dist-lib/esm-chunks/{chunk-3IGU77CU.mjs → chunk-BJJ5YZB6.mjs} +1 -1
- package/dist-lib/esm-chunks/{chunk-YOYB5CUH.mjs → chunk-CU2BGZX6.mjs} +3 -3
- package/dist-lib/esm-chunks/{chunk-4WB5MYZK.mjs → chunk-EHCUOL6F.mjs} +1 -1
- package/dist-lib/esm-chunks/{chunk-KIVEUIH6.mjs → chunk-EPUMB2XB.mjs} +1 -1
- package/dist-lib/esm-chunks/{chunk-HPTFLXNS.mjs → chunk-ESH5LJOH.mjs} +1 -1
- package/dist-lib/esm-chunks/{chunk-MLNLWTQ4.mjs → chunk-FEC6H5QL.mjs} +1 -1
- package/dist-lib/esm-chunks/{chunk-XBACEBHO.mjs → chunk-GAEDNJAS.mjs} +4 -4
- package/dist-lib/esm-chunks/{chunk-JQ6UZ3VQ.mjs → chunk-GT3ADYH4.mjs} +1 -1
- package/dist-lib/esm-chunks/{chunk-SWXK4DCF.mjs → chunk-GV67FFM6.mjs} +1 -1
- package/dist-lib/esm-chunks/{chunk-RKIDRF75.mjs → chunk-JABXIJTY.mjs} +5 -5
- package/dist-lib/esm-chunks/{chunk-TO5CGUCB.mjs → chunk-KE7VRNGK.mjs} +2 -2
- package/dist-lib/esm-chunks/{chunk-ZT5X25PU.mjs → chunk-NQBE6OUN.mjs} +1 -1
- package/dist-lib/esm-chunks/{chunk-YUCUQLXS.mjs → chunk-QBUIEC3Q.mjs} +1 -1
- package/dist-lib/esm-chunks/{chunk-MHBGSDCW.mjs → chunk-QNQSRP6K.mjs} +1 -1
- package/dist-lib/esm-chunks/{chunk-WFHGM56W.mjs → chunk-RSK7YOQW.mjs} +1 -1
- package/dist-lib/esm-chunks/{chunk-IUZV2QFS.mjs → chunk-TW5TQVFF.mjs} +1 -1
- package/dist-lib/esm-chunks/{chunk-EYNUEBZS.mjs → chunk-UEUASU5U.mjs} +1 -1
- package/dist-lib/esm-chunks/{chunk-S4ILTSHU.mjs → chunk-VUIHHG2L.mjs} +13 -13
- package/dist-lib/esm-chunks/{metro-layout-parser-HKVS23KL.mjs → metro-layout-parser-IMUYCZFS.mjs} +3 -3
- package/dist-lib/esm-chunks/{swift-package-prebuilt-IXPE5QKE.mjs → swift-package-prebuilt-RH6SSCXW.mjs} +10 -10
- package/dist-lib/esm-chunks/{swift-sdk-app-module-MFYSYZV7.mjs → swift-sdk-app-module-C5ADG7WT.mjs} +14 -14
- package/dist-lib/esm-chunks/{swift-sdk-image-ELK3I3RE.mjs → swift-sdk-image-CRWKDNXU.mjs} +14 -14
- package/dist-lib/esm-chunks/{swift-sdk-image-producer-5PGLTLYT.mjs → swift-sdk-image-producer-WBUYIGYR.mjs} +4 -4
- package/dist-lib/expo-swift-bundle.cjs +8 -8
- package/dist-lib/expo-swift-metadata.cjs +1 -1
- package/dist-lib/expo-swift-metadata.mjs +7 -7
- package/dist-lib/home-paths.cjs +1 -1
- package/dist-lib/host/bridge-host.cjs +28 -46
- package/dist-lib/host/fetch-proxy-handler.cjs +8 -8
- package/dist-lib/host/fetch-proxy-overrides.cjs +1 -1
- package/dist-lib/host/fetch-proxy-overrides.mjs +2 -2
- package/dist-lib/host/replacement-module-handler.cjs +1 -1
- package/dist-lib/host/websocket-proxy.cjs +1 -1
- package/dist-lib/index.cjs +2 -2
- package/dist-lib/kotlin-host.cjs +1 -1
- package/dist-lib/menu.cjs +1 -1
- package/dist-lib/menu.mjs +3 -3
- package/dist-lib/metro-fingerprint-registry.cjs +1 -1
- package/dist-lib/metro-fingerprint-registry.mjs +3 -3
- package/dist-lib/metro-production-bundle.cjs +1 -1
- package/dist-lib/metro-production-bundle.mjs +4 -4
- package/dist-lib/native-app-identity-project.cjs +3 -3
- package/dist-lib/native-app-identity-project.mjs +17 -17
- package/dist-lib/native-app-identity.cjs +1 -1
- package/dist-lib/native-app-identity.mjs +6 -6
- package/dist-lib/native-firebase-metadata.cjs +1 -1
- package/dist-lib/native-firebase-metadata.mjs +3 -3
- package/dist-lib/pdfium-raster.cjs +1 -1
- package/dist-lib/pdfium-raster.mjs +2 -2
- package/dist-lib/plist.cjs +1 -1
- package/dist-lib/plist.mjs +3 -3
- package/dist-lib/profiles.cjs +1 -1
- package/dist-lib/public-brand.cjs +1 -1
- package/dist-lib/public-origins-lib-esm.json +81 -81
- package/dist-lib/public-origins-lib.json +69 -69
- package/dist-lib/react-native-host-modules.cjs +1 -1
- package/dist-lib/react-native-host-modules.mjs +2 -2
- package/dist-lib/reap-browser.cjs +1 -1
- package/dist-lib/scripts/dev-server-scanner.cjs +1 -1
- package/dist-lib/sdk.cjs +1 -1
- package/dist-lib/sdk.mjs +8 -8
- package/dist-lib/skills.cjs +48 -51
- package/dist-lib/swift-compile.cjs +2 -2
- package/dist-lib/swift-compile.mjs +10 -10
- package/dist-lib/swift-package.cjs +1 -1
- package/dist-lib/swift-package.mjs +3 -3
- package/dist-lib/swift-submit.cjs +1 -1
- package/dist-lib/swift-submit.mjs +6 -6
- package/dist-lib/swift-svg-raster.cjs +1 -1
- package/dist-lib/swift-svg-raster.mjs +2 -2
- package/dist-lib/swift-toolchain.cjs +8 -1
- package/dist-lib/swift.cjs +1 -1
- package/dist-lib/vendor/@peculiar/x509.cjs +1 -1
- package/dist-lib/vendor/@ruby/prism/src/nodes.js.cjs +1 -1
- package/dist-lib/vendor/@ruby/prism/src/parsePrism.js.cjs +1 -1
- package/dist-lib/vendor/@xmldom/xmldom.cjs +1 -1
- package/dist-lib/vendor/acorn.cjs +1 -1
- package/dist-lib/vendor/bplist-parser.cjs +1 -1
- package/dist-lib/vendor/ignore.cjs +1 -1
- package/dist-lib/vendor/magic-string.cjs +1 -1
- package/dist-lib/vendor/plist.cjs +1 -1
- package/dist-lib/vendor/smol-toml.cjs +1 -1
- package/dist-lib/vendor/stream-json.cjs +1 -1
- package/dist-lib/vendor/sucrase/dist/index.js.cjs +1 -1
- package/dist-lib/vendor/sucrase/dist/parser/index.js.cjs +1 -1
- package/dist-lib/vendor/sucrase/dist/parser/tokenizer/index.js.cjs +1 -1
- package/dist-lib/vendor/sucrase/dist/parser/tokenizer/types.js.cjs +1 -1
- package/dist-lib/vendor/sucrase.cjs +1 -1
- package/dist-lib/vendor/terser.cjs +1 -1
- package/dist-lib/vendor/valibot.cjs +1 -1
- package/dist-lib/vendor/ws.cjs +1 -1
- package/dist-lib/vendor/zod.cjs +1 -1
- package/dist-lib/worklet-executable.cjs +1 -1
- package/dist-lib/worklet-executable.mjs +3 -3
- package/package.json +1 -1
- package/src/native-static-libraries.ts +3 -3
- package/src/one-native-controls-package.ts +1 -1
- package/src/one-native-source.ts +22 -46
- package/src/swift-toolchain.ts +6 -0
- package/src/vite-plugin.ts +4 -2
package/dist-lib/vendor/zod.cjs
CHANGED
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
/*! peach v0.1.
|
|
1
|
+
/*! peach v0.1.2569 | (c) 2026 Tamagui LLC | Proprietary; see LICENSE */
|
|
2
2
|
let __sootsim_import_meta_url = '', __sootsim_import_meta_dirname = '', __sootsim_import_meta_filename = ''; try { __sootsim_import_meta_url = require('url').pathToFileURL(__filename).href; __sootsim_import_meta_dirname = __dirname; __sootsim_import_meta_filename = __filename; } catch {}
|
|
3
3
|
"use strict";
|
|
4
4
|
var __getOwnPropNames = Object.getOwnPropertyNames;
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
/*! peach v0.1.
|
|
1
|
+
/*! peach v0.1.2569 | (c) 2026 Tamagui LLC | Proprietary; see LICENSE */
|
|
2
2
|
let __sootsim_import_meta_url = '', __sootsim_import_meta_dirname = '', __sootsim_import_meta_filename = ''; try { __sootsim_import_meta_url = require('url').pathToFileURL(__filename).href; __sootsim_import_meta_dirname = __dirname; __sootsim_import_meta_filename = __filename; } catch {}
|
|
3
3
|
"use strict";
|
|
4
4
|
var __defProp = Object.defineProperty;
|
|
@@ -1,12 +1,12 @@
|
|
|
1
|
-
/*! peach v0.1.
|
|
1
|
+
/*! peach v0.1.2569 | (c) 2026 Tamagui LLC | Proprietary; see LICENSE */
|
|
2
2
|
import {
|
|
3
3
|
parse
|
|
4
|
-
} from "./esm-chunks/chunk-
|
|
4
|
+
} from "./esm-chunks/chunk-TW5TQVFF.mjs";
|
|
5
5
|
import {
|
|
6
6
|
__privateAdd,
|
|
7
7
|
__privateGet,
|
|
8
8
|
__publicField
|
|
9
|
-
} from "./esm-chunks/chunk-
|
|
9
|
+
} from "./esm-chunks/chunk-BJJ5YZB6.mjs";
|
|
10
10
|
|
|
11
11
|
// src/worklet-kernel.ts
|
|
12
12
|
var Unsupported = class extends Error {
|
package/package.json
CHANGED
|
@@ -184,7 +184,7 @@ export const NATIVE_STATIC_LIBRARY_RECIPES = [
|
|
|
184
184
|
runtime: 'rust',
|
|
185
185
|
nativeSha256: '03b721dd9e98ec2767f7952aa65cde57d0c33d7ec80c9aaf7ab5ba77e055a25c',
|
|
186
186
|
upstream: 'e41ad6375fd80b64c4183d1a3f901d1f640a7953',
|
|
187
|
-
recipe: '
|
|
187
|
+
recipe: '4cdc7bf066ed3609c801cfd8836b7ea3b1c435159213a491765a343e1398d7ef',
|
|
188
188
|
archive: 'libanydoc_mobile.a',
|
|
189
189
|
},
|
|
190
190
|
{
|
|
@@ -193,7 +193,7 @@ export const NATIVE_STATIC_LIBRARY_RECIPES = [
|
|
|
193
193
|
nativeSha256: '8c41abcd8dd4e562e65cf5b88467a3493089c359d0863360dc65a5b88149e837',
|
|
194
194
|
upstream: 'a4296fa21cd40a56543602511bcf417014f4fee7cf5e1eaab58e0ac9610e3f63',
|
|
195
195
|
// the unchanged source build, pinned Rust release and committed Cargo.lock.
|
|
196
|
-
recipe: '
|
|
196
|
+
recipe: 'b1cabf413e6d9df99c3195f93bc3a56858d193a10949785dc6a7db011293155f',
|
|
197
197
|
archive: 'libratex_ffi.a',
|
|
198
198
|
},
|
|
199
199
|
{
|
|
@@ -201,7 +201,7 @@ export const NATIVE_STATIC_LIBRARY_RECIPES = [
|
|
|
201
201
|
runtime: 'rust',
|
|
202
202
|
nativeSha256: 'bdd2bf679fcc981d98d36733b3bd083225a7397bb82bbd462c89088c6e0580a8',
|
|
203
203
|
upstream: '2da907eb5dfcb464c7eef3b4c657fbdee144e3c6633e81efb1e56dcf1c76e01b',
|
|
204
|
-
recipe: '
|
|
204
|
+
recipe: '1c737b1d2f4f106632bcd58a93f58c738960b945d9d8b0b2599a14137d187b53',
|
|
205
205
|
archive: 'libratex_ffi.a',
|
|
206
206
|
},
|
|
207
207
|
// react-native-skia 2.14.0 (apple-ios 154.0.0), then 3.8.0 (157): installed apps pin either.
|
|
@@ -421,7 +421,7 @@ private let startupProfileSpec: [String: Any] = [
|
|
|
421
421
|
"spec": [
|
|
422
422
|
"control": "OneNativeButton",
|
|
423
423
|
"buttonRole": "confirm",
|
|
424
|
-
"swiftStyle": ["sdkModifiers": #"[["disabled",true]]"#],
|
|
424
|
+
"swiftStyle": ["sdkModifiers": #"[["disabled","true"]]"#],
|
|
425
425
|
],
|
|
426
426
|
"children": [
|
|
427
427
|
[
|
package/src/one-native-source.ts
CHANGED
|
@@ -5,7 +5,7 @@
|
|
|
5
5
|
import fs from 'node:fs'
|
|
6
6
|
import { createRequire } from 'node:module'
|
|
7
7
|
import path from 'node:path'
|
|
8
|
-
import {
|
|
8
|
+
import { pathToFileURL } from 'node:url'
|
|
9
9
|
import { promisify } from 'node:util'
|
|
10
10
|
import { brotliCompress, constants } from 'node:zlib'
|
|
11
11
|
import { KOTLIN_PACKAGE_PATH } from '@peach/globals/kotlin-discovery'
|
|
@@ -18,7 +18,7 @@ import { ONE_NATIVE_CONTROLS_PACKAGE } from './oneNativeControlsContract'
|
|
|
18
18
|
import { ONE_WIDGET_PATH } from './oneWidgetContract'
|
|
19
19
|
import { swiftPackageMetadata, swiftPackageWatchFiles } from './swift-host'
|
|
20
20
|
import { SWIFT_HMR_PATH, SWIFT_PACKAGE_PATH } from './swift-submit'
|
|
21
|
-
import {
|
|
21
|
+
import { localSwiftModuleRoot } from './swift-toolchain'
|
|
22
22
|
import type { IncomingMessage, ServerResponse } from 'node:http'
|
|
23
23
|
import type { Duplex } from 'node:stream'
|
|
24
24
|
|
|
@@ -36,21 +36,15 @@ interface App {
|
|
|
36
36
|
const apps = new Map<string, App>()
|
|
37
37
|
const compressMetadata = promisify(brotliCompress)
|
|
38
38
|
|
|
39
|
-
|
|
40
|
-
// and its packages compile on Contrast
|
|
41
|
-
function swiftModuleRoot(): string | undefined {
|
|
42
|
-
if (privateSwiftDistributionRoot()) return undefined
|
|
43
|
-
const root = path.resolve(
|
|
44
|
-
path.dirname(fileURLToPath(import.meta.url)),
|
|
45
|
-
'../../sootsim-swift',
|
|
46
|
-
)
|
|
47
|
-
return fs.existsSync(path.join(root, 'toolchain.json')) ? root : undefined
|
|
48
|
-
}
|
|
49
|
-
|
|
50
|
-
function appFor(url: URL, origin: string): App | null {
|
|
39
|
+
function appFor(url: URL, origin: string, allowRootless: boolean): App | null {
|
|
51
40
|
const requested = url.searchParams.get('root')
|
|
52
|
-
if (
|
|
53
|
-
|
|
41
|
+
if (
|
|
42
|
+
requested === null
|
|
43
|
+
? !allowRootless
|
|
44
|
+
: !path.isAbsolute(requested) || !fs.existsSync(requested)
|
|
45
|
+
)
|
|
46
|
+
return null
|
|
47
|
+
const root = requested === null ? '' : fs.realpathSync(requested)
|
|
54
48
|
let app = apps.get(root)
|
|
55
49
|
if (!app) {
|
|
56
50
|
app = {
|
|
@@ -61,6 +55,8 @@ function appFor(url: URL, origin: string): App | null {
|
|
|
61
55
|
active: new Map(),
|
|
62
56
|
}
|
|
63
57
|
apps.set(root, app)
|
|
58
|
+
} else if (!root) {
|
|
59
|
+
app.origin = origin
|
|
64
60
|
}
|
|
65
61
|
return app
|
|
66
62
|
}
|
|
@@ -101,7 +97,7 @@ async function packageMetadata(app: App, packageName: string) {
|
|
|
101
97
|
!builtinControls && packageName === ONE_WIDGET_PACKAGE
|
|
102
98
|
? await oneWidgetPackage(app.root)
|
|
103
99
|
: null
|
|
104
|
-
if (!builtinControls
|
|
100
|
+
if (!builtinControls) app.packages ??= await swiftPackages(app.root)
|
|
105
101
|
if (widget && app.packages?.has(packageName))
|
|
106
102
|
throw new Error(
|
|
107
103
|
`swift package ${packageName} conflicts with One's generated widget extension`,
|
|
@@ -109,7 +105,7 @@ async function packageMetadata(app: App, packageName: string) {
|
|
|
109
105
|
const packagePath =
|
|
110
106
|
builtinControls?.packagePath ?? widget?.packagePath ?? app.packages?.get(packageName)
|
|
111
107
|
if (!packagePath) throw new Error(`swift package ${packageName} was not found`)
|
|
112
|
-
const moduleRoot =
|
|
108
|
+
const moduleRoot = localSwiftModuleRoot()
|
|
113
109
|
const built = await swiftPackageMetadata(
|
|
114
110
|
packagePath,
|
|
115
111
|
packageName,
|
|
@@ -195,31 +191,11 @@ export async function handleOneNativeSourceRequest(
|
|
|
195
191
|
}
|
|
196
192
|
res.setHeader('access-control-allow-origin', req.headers.origin ?? '*')
|
|
197
193
|
res.setHeader('vary', 'origin')
|
|
198
|
-
const
|
|
194
|
+
const packageName = isSwift
|
|
199
195
|
? decodeURIComponent(url.pathname.slice(SWIFT_PACKAGE_PATH.length))
|
|
200
196
|
: null
|
|
201
197
|
const origin = req.headers.host ? `http://${req.headers.host}` : null
|
|
202
|
-
const app =
|
|
203
|
-
origin &&
|
|
204
|
-
(appFor(url, origin) ??
|
|
205
|
-
(builtinControlsName === ONE_NATIVE_CONTROLS_PACKAGE
|
|
206
|
-
? (() => {
|
|
207
|
-
let shared = apps.get('')
|
|
208
|
-
if (!shared) {
|
|
209
|
-
shared = {
|
|
210
|
-
root: '',
|
|
211
|
-
origin,
|
|
212
|
-
sockets: new WebSocketServer({ noServer: true }),
|
|
213
|
-
watched: new Set(),
|
|
214
|
-
active: new Map(),
|
|
215
|
-
}
|
|
216
|
-
apps.set('', shared)
|
|
217
|
-
} else {
|
|
218
|
-
shared.origin = origin
|
|
219
|
-
}
|
|
220
|
-
return shared
|
|
221
|
-
})()
|
|
222
|
-
: null))
|
|
198
|
+
const app = origin && appFor(url, origin, packageName === ONE_NATIVE_CONTROLS_PACKAGE)
|
|
223
199
|
if (!app) {
|
|
224
200
|
res.writeHead(400)
|
|
225
201
|
res.end('missing absolute app root')
|
|
@@ -240,10 +216,7 @@ export async function handleOneNativeSourceRequest(
|
|
|
240
216
|
res.end(JSON.stringify(widget))
|
|
241
217
|
return true
|
|
242
218
|
}
|
|
243
|
-
if (
|
|
244
|
-
const packageName = decodeURIComponent(
|
|
245
|
-
url.pathname.slice(SWIFT_PACKAGE_PATH.length),
|
|
246
|
-
)
|
|
219
|
+
if (packageName !== null) {
|
|
247
220
|
const metadata = await packageMetadata(app, packageName)
|
|
248
221
|
const body = JSON.stringify(metadata)
|
|
249
222
|
const acceptsBrotli = req.headers['accept-encoding']?.split(',').some((value) => {
|
|
@@ -290,8 +263,11 @@ export function handleOneNativeSourceUpgrade(
|
|
|
290
263
|
): boolean {
|
|
291
264
|
const url = new URL(req.url ?? '/', 'http://localhost')
|
|
292
265
|
if (url.pathname !== SWIFT_HMR_PATH) return false
|
|
293
|
-
const app =
|
|
294
|
-
|
|
266
|
+
const app =
|
|
267
|
+
req.headers.host && loopbackClient(req)
|
|
268
|
+
? appFor(url, `http://${req.headers.host}`, true)
|
|
269
|
+
: null
|
|
270
|
+
if (!app) {
|
|
295
271
|
socket.destroy()
|
|
296
272
|
return true
|
|
297
273
|
}
|
package/src/swift-toolchain.ts
CHANGED
|
@@ -292,6 +292,12 @@ export function privateSwiftDistributionRoot(): string | null {
|
|
|
292
292
|
return root ? path.resolve(root) : null
|
|
293
293
|
}
|
|
294
294
|
|
|
295
|
+
export function localSwiftModuleRoot(): string | undefined {
|
|
296
|
+
if (privateSwiftDistributionRoot()) return undefined
|
|
297
|
+
const root = path.resolve(peachsimPackageRoot(), '../sootsim-swift')
|
|
298
|
+
return fs.existsSync(path.join(root, 'toolchain.json')) ? root : undefined
|
|
299
|
+
}
|
|
300
|
+
|
|
295
301
|
// the private distribution's own compiler release: the only one accepted without
|
|
296
302
|
// a qualified archive entry.
|
|
297
303
|
export function privateSwiftCompilerRelease(): string | null {
|
package/src/vite-plugin.ts
CHANGED
|
@@ -2169,8 +2169,10 @@ export function workerReactBridgePlugin(): Plugin {
|
|
|
2169
2169
|
async handler(_source, importer, options) {
|
|
2170
2170
|
if (!importer) return null
|
|
2171
2171
|
|
|
2172
|
-
// skip during dep scanning
|
|
2173
|
-
|
|
2172
|
+
// skip during dep scanning; do not skip options.ssr because node-tenant
|
|
2173
|
+
// builds with build.ssr = true to emit a Node ESM bundle, and its
|
|
2174
|
+
// reconciler still needs the react bridge so bindReact(guestReact) works.
|
|
2175
|
+
if ((options as { scan?: boolean })?.scan) return null
|
|
2174
2176
|
|
|
2175
2177
|
// redirect react imports from peachsim, peach-engine, peach-compat, react-reconciler,
|
|
2176
2178
|
// and any pure-JS RN-ecosystem package the bundle pulls in. without this
|