@legendapp/spark 0.0.1-next.9 → 0.0.2

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.
Files changed (104) hide show
  1. package/native.d.cts +6 -3
  2. package/package.json +36 -28
  3. package/patches/react-native-enriched-markdown@1.1.1.patch +2000 -3379
  4. package/skills/spark/UPGRADING.md +106 -3
  5. package/vendor/node_modules/@legendapp/spark-ai/package.json +5 -5
  6. package/vendor/node_modules/@legendapp/spark-audio/package.json +5 -5
  7. package/vendor/node_modules/@legendapp/spark-audio/src/index.macos.ts +1 -0
  8. package/vendor/node_modules/@legendapp/spark-auth-session/package.json +6 -6
  9. package/vendor/node_modules/@legendapp/spark-auth-session/src/index.macos.ts +1 -0
  10. package/vendor/node_modules/@legendapp/spark-cli/dist/add-desktop.js +2 -2
  11. package/vendor/node_modules/@legendapp/spark-cli/dist/build.js +11 -2
  12. package/vendor/node_modules/@legendapp/spark-cli/dist/cli-arguments.js +4 -2
  13. package/vendor/node_modules/@legendapp/spark-cli/dist/create.js +8 -4
  14. package/vendor/node_modules/@legendapp/spark-cli/dist/dependency-pins.js +45 -1
  15. package/vendor/node_modules/@legendapp/spark-cli/dist/dev.js +13 -2
  16. package/vendor/node_modules/@legendapp/spark-cli/dist/examples.js +2 -2
  17. package/vendor/node_modules/@legendapp/spark-cli/dist/expo-dev-patch.cjs +3 -3
  18. package/vendor/node_modules/@legendapp/spark-cli/dist/expo-dev-preload.cjs +3 -0
  19. package/vendor/node_modules/@legendapp/spark-cli/dist/index.js +26 -7
  20. package/vendor/node_modules/@legendapp/spark-cli/dist/metro.cjs +3 -1
  21. package/vendor/node_modules/@legendapp/spark-cli/dist/migration-helpers.cjs +20 -5
  22. package/vendor/node_modules/@legendapp/spark-cli/dist/migration-helpers.d.cts +1 -0
  23. package/vendor/node_modules/@legendapp/spark-cli/dist/migrations.cjs +7 -2
  24. package/vendor/node_modules/@legendapp/spark-cli/dist/native-patch-preflight.js +3 -3
  25. package/vendor/node_modules/@legendapp/spark-cli/dist/project.js +16 -10
  26. package/vendor/node_modules/@legendapp/spark-cli/dist/release-runner-root.js +108 -0
  27. package/vendor/node_modules/@legendapp/spark-cli/dist/release.json +13 -13
  28. package/vendor/node_modules/@legendapp/spark-cli/dist/runner-install.js +4 -2
  29. package/vendor/node_modules/@legendapp/spark-cli/dist/session-status.js +7 -3
  30. package/vendor/node_modules/@legendapp/spark-cli/dist/watchman.js +12 -0
  31. package/vendor/node_modules/@legendapp/spark-cli/dist/windows-geometry.js +2 -2
  32. package/vendor/node_modules/@legendapp/spark-cli/dist/windows.js +1 -1
  33. package/vendor/node_modules/@legendapp/spark-cli/package.json +3 -3
  34. package/vendor/node_modules/@legendapp/spark-cli/templates/blank-typescript/desktop.config.json +1 -1
  35. package/vendor/node_modules/@legendapp/spark-cli/templates/blank-typescript/package.json +27 -25
  36. package/vendor/node_modules/@legendapp/spark-cli/templates/universal/desktop.config.json +1 -1
  37. package/vendor/node_modules/@legendapp/spark-cli/templates/universal/package.json +35 -33
  38. package/vendor/node_modules/@legendapp/spark-cli/templates/windows/package.json +29 -27
  39. package/vendor/node_modules/@legendapp/spark-clipboard/package.json +5 -5
  40. package/vendor/node_modules/@legendapp/spark-clipboard/src/index.macos.ts +1 -0
  41. package/vendor/node_modules/@legendapp/spark-codex/package.json +4 -4
  42. package/vendor/node_modules/@legendapp/spark-commands/package.json +7 -7
  43. package/vendor/node_modules/@legendapp/spark-context-menu/package.json +4 -4
  44. package/vendor/node_modules/@legendapp/spark-desktop-app/macos/SparkDesktop.mm +7 -2
  45. package/vendor/node_modules/@legendapp/spark-desktop-app/package.json +3 -3
  46. package/vendor/node_modules/@legendapp/spark-desktop-config/accessibility-state.cjs +2 -2
  47. package/vendor/node_modules/@legendapp/spark-desktop-config/app.plugin.cjs +12 -0
  48. package/vendor/node_modules/@legendapp/spark-desktop-config/autolinking.cjs +4 -4
  49. package/vendor/node_modules/@legendapp/spark-desktop-config/config.d.cts +1 -1
  50. package/vendor/node_modules/@legendapp/spark-desktop-config/fabric-lifecycle.cjs +1 -1
  51. package/vendor/node_modules/@legendapp/spark-desktop-config/keyboard-events.cjs +2 -2
  52. package/vendor/node_modules/@legendapp/spark-desktop-config/macos-host.cjs +39 -0
  53. package/vendor/node_modules/@legendapp/spark-desktop-config/native-patches.cjs +47 -12
  54. package/vendor/node_modules/@legendapp/spark-desktop-config/native-patches.d.cts +2 -1
  55. package/vendor/node_modules/@legendapp/spark-desktop-config/package.json +8 -6
  56. package/vendor/node_modules/@legendapp/spark-desktop-config/rtl-scroll-view.cjs +2 -2
  57. package/vendor/node_modules/@legendapp/spark-desktop-config/rtl-text-alignment.cjs +2 -2
  58. package/vendor/node_modules/@legendapp/spark-desktop-config/rtl-text-input-alignment.cjs +2 -2
  59. package/vendor/node_modules/@legendapp/spark-desktop-config/text-input-accessibility.cjs +2 -2
  60. package/vendor/node_modules/@legendapp/spark-desktop-host/macos/AppDelegate.h +6 -0
  61. package/vendor/node_modules/@legendapp/spark-desktop-host/macos/Main.storyboard +684 -0
  62. package/vendor/node_modules/@legendapp/spark-desktop-host/macos/main.m +5 -0
  63. package/vendor/node_modules/@legendapp/spark-desktop-host/package.json +3 -2
  64. package/vendor/node_modules/@legendapp/spark-desktop-links/package.json +5 -5
  65. package/vendor/node_modules/@legendapp/spark-desktop-links/src/index.macos.ts +1 -0
  66. package/vendor/node_modules/@legendapp/spark-desktop-shortcuts/package.json +4 -4
  67. package/vendor/node_modules/@legendapp/spark-desktop-windows/macos/window-manager/RNWindowManager.mm +68 -17
  68. package/vendor/node_modules/@legendapp/spark-desktop-windows/package.json +5 -5
  69. package/vendor/node_modules/@legendapp/spark-desktop-windows/src/macos-adapter.ts +2 -1
  70. package/vendor/node_modules/@legendapp/spark-documents/package.json +9 -9
  71. package/vendor/node_modules/@legendapp/spark-drag-drop/package.json +4 -4
  72. package/vendor/node_modules/@legendapp/spark-file-dialog/package.json +4 -4
  73. package/vendor/node_modules/@legendapp/spark-file-system/macos/RNDesktopFileSystem.mm +14 -5
  74. package/vendor/node_modules/@legendapp/spark-file-system/package.json +4 -4
  75. package/vendor/node_modules/@legendapp/spark-file-system/src/index.ts +1 -1
  76. package/vendor/node_modules/@legendapp/spark-global-shortcuts/package.json +4 -4
  77. package/vendor/node_modules/@legendapp/spark-html/package.json +4 -4
  78. package/vendor/node_modules/@legendapp/spark-markdown/package.json +4 -4
  79. package/vendor/node_modules/@legendapp/spark-message-dialog/package.json +4 -4
  80. package/vendor/node_modules/@legendapp/spark-native-menu/package.json +4 -4
  81. package/vendor/node_modules/@legendapp/spark-notifications/package.json +4 -4
  82. package/vendor/node_modules/@legendapp/spark-processes/macos/RNDesktopProcesses.mm +110 -19
  83. package/vendor/node_modules/@legendapp/spark-processes/package.json +4 -4
  84. package/vendor/node_modules/@legendapp/spark-processes/src/index.ts +17 -3
  85. package/vendor/node_modules/@legendapp/spark-processes/src/types.ts +6 -0
  86. package/vendor/node_modules/@legendapp/spark-rich-text/package.json +4 -4
  87. package/vendor/node_modules/@legendapp/spark-secure-storage/package.json +5 -5
  88. package/vendor/node_modules/@legendapp/spark-secure-storage/src/index.macos.ts +1 -0
  89. package/vendor/node_modules/@legendapp/spark-settings/package.json +3 -3
  90. package/vendor/node_modules/@legendapp/spark-settings-ui/package.json +6 -6
  91. package/vendor/node_modules/@legendapp/spark-sqlite/package.json +12 -5
  92. package/vendor/node_modules/@legendapp/spark-system/package.json +4 -4
  93. package/vendor/node_modules/@legendapp/spark-tray/package.json +4 -4
  94. package/vendor/node_modules/@legendapp/spark-ui/macos/appkit-split-view/RNSidebarSplitViewComponent.mm +82 -18
  95. package/vendor/node_modules/@legendapp/spark-ui/package.json +6 -6
  96. package/vendor/node_modules/@legendapp/spark-ui/src/appkit-split-view/SidebarSplitViewNativeComponent.ts +4 -0
  97. package/vendor/node_modules/@legendapp/spark-ui/src/appkit-split-view/index.tsx +11 -9
  98. package/vendor/node_modules/@legendapp/spark-ui/src/index.android.tsx +20 -10
  99. package/vendor/node_modules/@legendapp/spark-ui/src/index.ios.tsx +15 -10
  100. package/vendor/node_modules/@legendapp/spark-ui/src/index.macos.tsx +1 -0
  101. package/vendor/node_modules/@legendapp/spark-updates/package.json +4 -4
  102. package/vendor/node_modules/@legendapp/spark-webview/package.json +11 -4
  103. package/vendor/node_modules/@legendapp/spark-window-options/package.json +1 -1
  104. package/camera.ts +0 -13
@@ -211,9 +211,10 @@ After (for this release):
211
211
  ```
212
212
 
213
213
  Camera and enriched Markdown native dependency patches are applied by the SDK.
214
- Use public `/camera` and `/markdown` imports; stop manually patching their bundled
215
- dependencies. Existing custom runtimes must rebuild to include changed native
216
- code. Native production builds fail when app source imports an excluded module:
214
+ Use public `/camera` (removed in 0.0.2 — import `react-native-vision-camera`
215
+ directly) and `/markdown` imports; stop manually patching their bundled dependencies.
216
+ Existing custom runtimes must rebuild to include changed native code. Native
217
+ production builds fail when app source imports an excluded module:
217
218
  check `spark analyze` and native-only `include` requirements rather than weakening
218
219
  the selection. SidebarSplitView gained a native content-list column and swipe
219
220
  actions; review customized pane composition if affected. Windows notification
@@ -302,3 +303,105 @@ Starters also pin Expo to `54.0.37` throughout the dependency graph.
302
303
  Yarn 4 can resolve to a second Expo version alongside the starter's exact pin.
303
304
  For existing Yarn apps on this SDK, add `"expo": "54.0.37"` to `resolutions`
304
305
  and run `yarn install`; Spark's native preflight requires one Expo version.
306
+
307
+ ## 0.0.1-next.10
308
+
309
+ Clearer wording when a new app downloads the prebuilt Spark Runner: `spark dev` (and `npm run macos`) shows `Downloading Spark Runner (20.6 MB)…` with a progress bar after Metro starts, then `Spark Runner installed, opening your app…`. The "Press d to install and open it" prompt now appears only when the session doesn't open the desktop app by itself, such as with `--no-open`. No changes are needed in existing apps.
310
+
311
+ ## 0.0.1
312
+
313
+ The first stable release. It contains everything from `0.0.1-next.9`, plus
314
+ clearer wording when a new app downloads the prebuilt Spark Runner.
315
+
316
+ `spark dev` (and `npm run macos`) now downloads the Runner automatically and
317
+ shows `Downloading Spark Runner (20.6 MB)…` with a progress bar after Metro
318
+ starts, then `Spark Runner installed, opening your app…`. The old "Press d to
319
+ install and open it" prompt now appears only when the session doesn't open the
320
+ desktop app by itself, such as with `--no-open`.
321
+
322
+ No changes are needed in existing apps. Update `@legendapp/spark` to `0.0.1`
323
+ and reinstall.
324
+
325
+ ## 0.0.2
326
+
327
+ Breaking: yes. Spark moves from Expo SDK 54 / React Native 0.81 to **Expo SDK 55
328
+ and React Native 0.83**, and `@legendapp/spark/camera` was removed.
329
+
330
+ ### Expo SDK 55 and React Native 0.83
331
+
332
+ The SDK now pins Expo 55.0.32, React Native 0.83.10, React 19.2.0, React Native
333
+ macOS 0.83.0 and React Native Windows 0.83.2, with the Expo Desktop SDK 55
334
+ packages (`expo-desktop-metro-config` 55.83.3, `expo-desktop-template-bare-minimum`
335
+ 55.83.10, `expo-desktop-modules-core` and `expo-desktop-stubs` 55.0.2). Expo
336
+ Desktop CLI, prebuild-config and config-plugins stay on their 1.x releases.
337
+ React peer ranges are now `^19.2.0`.
338
+
339
+ `spark upgrade` updates the SDK-pinned dependencies and overrides in
340
+ `package.json`. For example:
341
+
342
+ Before:
343
+ ```json
344
+ { "dependencies": { "expo": "54.0.37", "react": "19.1.4", "react-native": "0.81.6", "react-native-macos": "0.81.7" } }
345
+ ```
346
+ After:
347
+ ```json
348
+ { "dependencies": { "expo": "55.0.32", "react": "19.2.0", "react-native": "0.83.10", "react-native-macos": "0.83.0" } }
349
+ ```
350
+
351
+ It does not move Expo modules that only your app depends on (for example
352
+ `expo-image` or `expo-camera`). Move those to their Expo SDK 55 versions, then
353
+ review the Expo SDK 55 and React Native
354
+ 0.83 changelogs for APIs your app code and custom native modules use. Run
355
+ `spark doctor`, your typecheck and tests, rebuild custom runtimes
356
+ (`spark build --dev`), and exercise your app's desktop flows.
357
+
358
+ On Android, `@legendapp/spark/ui` `Select` segments now expose radio-button
359
+ accessibility semantics, so screen readers announce the selected option.
360
+
361
+ The `--universal` hint printed by the creator now names an exact
362
+ `npx @legendapp/create-spark@<version>` command.
363
+
364
+ ### Camera and optional backends
365
+
366
+ `@legendapp/spark/camera` was removed. Install
367
+ `react-native-vision-camera@5.2.3` and `react-native-nitro-image@0.15.2` in your
368
+ app, with `react-native-nitro-modules@0.37.0`. Import camera APIs directly from
369
+ `react-native-vision-camera`, and `NitroImage` / `Image` from
370
+ `react-native-nitro-image`. Spark still applies its version-pinned native patches
371
+ automatically when your app depends on these libraries. Rebuild custom runtimes.
372
+
373
+ The `/markdown`, `/html`, `/webview`, and `/sqlite` APIs remain available, but
374
+ Spark no longer installs their backends. Add only the libraries your app uses
375
+ to its own `dependencies`, retaining the SDK's tested overrides:
376
+
377
+ | Spark import | App dependency |
378
+ | --- | --- |
379
+ | `@legendapp/spark/markdown` | `react-native-enriched-markdown@1.1.1` |
380
+ | `@legendapp/spark/html` | `react-native-enriched-html@1.1.1` |
381
+ | `@legendapp/spark/webview` | `react-native-webview@16.0.0` |
382
+ | `@legendapp/spark/sqlite` | `@op-engineering/op-sqlite@18.2.1` |
383
+
384
+ For WebView and SQLite, keep the matching patched SDK archive override supplied
385
+ by `spark upgrade` or `spark add desktop`. Run your package manager's install,
386
+ then `spark doctor` and rebuild custom runtimes. Native discovery and patching
387
+ activate only for installed app dependencies; optional peers alone do not select
388
+ native code. Nitro Modules and Runtimes remain hard dependencies.
389
+
390
+ Universal apps targeting Windows must exclude `react-native-enriched-html` and
391
+ `react-native-enriched-markdown` in `expoByPlatform.windows.autolinking.exclude`
392
+ in `desktop.config.json`, because these backends have no Windows implementation.
393
+
394
+ The `/native` `NativeConfiguration` type now describes only Spark's emitted
395
+ `platforms` and `dependencies` overrides; use your own CLI configuration type for
396
+ extra project or dependency fields, preserved by `withSparkNative`.
397
+
398
+ New apps now get a placeholder bundle ID, `com.example.<app-name>`, instead of
399
+ `so.legend.spark.prototype.<app-name>`. Pass `--bundle-id com.yourcompany.myapp`
400
+ to `create` to choose one up front, or change `bundleIdentifier` in
401
+ `desktop.config.json` before you ship. Release builds warn while the ID still
402
+ starts with `com.example.`. Existing apps keep their ID.
403
+
404
+ `spark dev` no longer hangs on "Waiting for Watchman `watch-project`" when
405
+ Watchman stops responding. After 10 seconds it starts Metro without Watchman
406
+ for that session and suggests `watchman watch-del-all && watchman shutdown-server`
407
+ to fix it.
@@ -1,16 +1,16 @@
1
1
  {
2
2
  "name": "@legendapp/spark-ai",
3
- "version": "0.0.1-next.9",
3
+ "version": "0.0.2",
4
4
  "private": true,
5
5
  "main": "src/index.ts",
6
6
  "react-native": "src/index.ts",
7
7
  "dependencies": {
8
- "@legendapp/spark-desktop-app": "0.0.1-next.9",
9
- "@legendapp/spark-processes": "0.0.1-next.9"
8
+ "@legendapp/spark-desktop-app": "0.0.2",
9
+ "@legendapp/spark-processes": "0.0.2"
10
10
  },
11
11
  "peerDependencies": {
12
- "react": "^19.1.0",
13
- "react-native": "0.81.6"
12
+ "react": "^19.2.0",
13
+ "react-native": "0.83.10"
14
14
  },
15
15
  "license": "MIT",
16
16
  "files": [
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@legendapp/spark-audio",
3
- "version": "0.0.1-next.9",
3
+ "version": "0.0.2",
4
4
  "license": "MIT",
5
5
  "main": "src/index",
6
6
  "react-native": "src/index",
@@ -11,9 +11,9 @@
11
11
  "*.podspec"
12
12
  ],
13
13
  "peerDependencies": {
14
- "react": "^19.1.0",
15
- "react-native": "0.81.6",
16
- "expo-audio": "1.1.1"
14
+ "react": "^19.2.0",
15
+ "react-native": "0.83.10",
16
+ "expo-audio": "55.0.18"
17
17
  },
18
18
  "peerDependenciesMeta": {
19
19
  "expo-audio": {
@@ -47,6 +47,6 @@
47
47
  },
48
48
  "private": true,
49
49
  "dependencies": {
50
- "@legendapp/spark-desktop-app": "0.0.1-next.9"
50
+ "@legendapp/spark-desktop-app": "0.0.2"
51
51
  }
52
52
  }
@@ -0,0 +1 @@
1
+ export * from "./desktop";
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@legendapp/spark-auth-session",
3
- "version": "0.0.1-next.9",
3
+ "version": "0.0.2",
4
4
  "license": "MIT",
5
5
  "main": "src/index",
6
6
  "react-native": "src/index",
@@ -8,14 +8,14 @@
8
8
  "src"
9
9
  ],
10
10
  "dependencies": {
11
- "@legendapp/spark-desktop-links": "0.0.1-next.9",
11
+ "@legendapp/spark-desktop-links": "0.0.2",
12
12
  "base64-js": "1.5.1",
13
- "@legendapp/spark-desktop-app": "0.0.1-next.9"
13
+ "@legendapp/spark-desktop-app": "0.0.2"
14
14
  },
15
15
  "peerDependencies": {
16
- "react-native": "0.81.6",
17
- "expo-web-browser": "~15.0.10",
18
- "expo-crypto": "~15.0.8"
16
+ "react-native": "0.83.10",
17
+ "expo-web-browser": "~55.0.20",
18
+ "expo-crypto": "~55.0.19"
19
19
  },
20
20
  "peerDependenciesMeta": {
21
21
  "expo-web-browser": {
@@ -0,0 +1 @@
1
+ export * from "./index.ts";
@@ -58,7 +58,7 @@ export async function addDesktop(root, manifestFile) {
58
58
  const req = createRequire(pkgFile);
59
59
  const installed = (name) => readJson(req.resolve(`${name}/package.json`)).version;
60
60
  // Never upgrade the mobile baseline as a side effect of adding desktop.
61
- for (const [name, version] of Object.entries({ expo: "54.0.37", "react-native": "0.81.6", react: "19.1.4" })) {
61
+ for (const [name, version] of Object.entries({ expo: "55.0.32", "react-native": "0.83.10", react: "19.2.0" })) {
62
62
  let actual;
63
63
  try {
64
64
  actual = installed(name);
@@ -161,7 +161,7 @@ export async function addDesktop(root, manifestFile) {
161
161
  }
162
162
  // Resolve local transitive SDK packages without replacing any mobile pins.
163
163
  const vendor = ["@react-native-runtimes/core", "react-native-nitro-modules", "@op-engineering/op-sqlite", "react-native-webview"];
164
- const overrides = { ...Object.fromEntries(local.map(name => [name, dependencies[name]])), "@expo/cli": "54.0.27",
164
+ const overrides = { ...Object.fromEntries(local.map(name => [name, dependencies[name]])), "@expo/cli": "55.0.37",
165
165
  "react-native-macos": defaults.overrides["react-native-macos"], "react-native-windows": defaults.overrides["react-native-windows"] };
166
166
  for (const name of vendor) {
167
167
  if (archives[name]) {
@@ -134,6 +134,11 @@ export async function analyze(root) {
134
134
  ].join("\n"));
135
135
  return result;
136
136
  }
137
+ export function warnExampleBundleId(config) {
138
+ const id = config.expo?.macos?.bundleIdentifier;
139
+ if (id?.startsWith("com.example."))
140
+ console.warn(`Warning: the bundle ID is still the placeholder ${id}. Change bundleIdentifier in desktop.config.json to an ID you own before you distribute this app.`);
141
+ }
137
142
  export async function build(root, mode, force = false) {
138
143
  assertNativePatchPreflight(root);
139
144
  const lock = stateFile(root, "build.lock");
@@ -176,6 +181,8 @@ async function buildUnlocked(root, mode, force) {
176
181
  if (projectPlatform(root) === "windows")
177
182
  return buildWindows(root, mode, force);
178
183
  prepareConfig(root);
184
+ if (mode === "release")
185
+ warnExampleBundleId(readAppConfig(root));
179
186
  if (mode === "go") {
180
187
  const issues = goConfigurationIssues(readAppConfig(root));
181
188
  if (issues.length)
@@ -194,7 +201,9 @@ async function buildUnlocked(root, mode, force) {
194
201
  if (productionHash)
195
202
  runtime.fingerprint = digest(runtime.fingerprint + productionHash);
196
203
  const resultFile = stateFile(root, `${mode}-build.json`);
204
+ // RNW's CLI config probes for PowerShell when Expo autolinking loads it on macOS.
197
205
  const excludedNames = [...new Set([
206
+ "react-native-windows",
198
207
  ...(readAppConfig(root).expo.autolinking?.exclude ?? []),
199
208
  ...chosen.excluded.map((p) => p.name),
200
209
  ])];
@@ -259,7 +268,7 @@ async function buildUnlocked(root, mode, force) {
259
268
  "--platform",
260
269
  "macos",
261
270
  "--template",
262
- "expo-desktop-template-bare-minimum@54.81.6",
271
+ "expo-desktop-template-bare-minimum@55.83.10",
263
272
  "--no-install",
264
273
  // Template renaming is not idempotent (HelloWorld becomes
265
274
  // LegendHelloWorld, then LegendLegendHelloWorld). Native projects
@@ -324,7 +333,7 @@ async function buildUnlocked(root, mode, force) {
324
333
  "CODE_SIGNING_ALLOWED=NO",
325
334
  ...(mode === "release" ? macOSReleaseSettings : []),
326
335
  "-jobs",
327
- "8",
336
+ /^\d+$/.test(process.env.SPARK_XCODEBUILD_JOBS ?? "") ? process.env.SPARK_XCODEBUILD_JOBS : "8",
328
337
  "build",
329
338
  ], {
330
339
  // Absolute, like analysis: Metro resolves a relative entry from its server root.
@@ -1,7 +1,7 @@
1
1
  import { parseArgs } from "node:util";
2
2
  import { buildMode } from "./build-mode.js";
3
3
  const options = {
4
- example: { type: "string" }, "package-manager": { type: "string" },
4
+ example: { type: "string" }, "package-manager": { type: "string" }, "bundle-id": { type: "string" },
5
5
  runtime: { type: "string", multiple: true }, universal: { type: "boolean" },
6
6
  device: { type: "string" }, project: { type: "string" }, platform: { type: "string" },
7
7
  packages: { type: "string" }, port: { type: "string" }, runner: { type: "boolean" },
@@ -9,7 +9,7 @@ const options = {
9
9
  force: { type: "boolean" }, "dry-run": { type: "boolean" }, "submission-id": { type: "string" }, help: { type: "boolean", short: "h" },
10
10
  };
11
11
  const commands = {
12
- create: { flags: ["example", "package-manager", "universal", "platform", "packages"], arguments: [1, 1] },
12
+ create: { flags: ["example", "package-manager", "bundle-id", "universal", "platform", "packages"], arguments: [1, 1] },
13
13
  "add desktop": { flags: ["project", "packages"], arguments: [0, 0] },
14
14
  "sdk export": { flags: ["packages", "runtime"], arguments: [1, 1] },
15
15
  "sdk import": { flags: [], arguments: [1, 1] },
@@ -53,6 +53,8 @@ export function cliArguments(args) {
53
53
  throw new Error("Port must be an integer between 1 and 65535.");
54
54
  if (values["package-manager"] && !["npm", "pnpm", "yarn", "bun"].includes(values["package-manager"]))
55
55
  throw new Error("Package manager must be npm, pnpm, yarn, or bun.");
56
+ if (values["bundle-id"] !== undefined && !/^[A-Za-z][A-Za-z0-9-]*(\.[A-Za-z0-9-]+)+$/.test(values["bundle-id"]))
57
+ throw new Error("Bundle ID must be reverse DNS, such as com.yourcompany.myapp.");
56
58
  if (command === "build")
57
59
  buildMode(values);
58
60
  if (command === "sdk build-runner" && values.project && (values.packages || values["package-manager"]))
@@ -46,7 +46,9 @@ export async function refreshLocalPackages(root, manifest, selectedManager) {
46
46
  await installWithEnrichedHtmlPins(root, manager);
47
47
  upgradeManagedEntry(root);
48
48
  }
49
- export async function create(root, archiveManifest, platform = hostPlatform(), universal = false, example, selectedManager) {
49
+ /** A placeholder ID for new apps: lowercase letters, digits and hyphens, starting with a letter. */
50
+ export const exampleBundleId = (name) => `com.example.${name.toLowerCase().replace(/[^a-z0-9-]/g, "").replace(/^[^a-z]+/, "") || "app"}`;
51
+ export async function create(root, archiveManifest, platform = hostPlatform(), universal = false, example, selectedManager, bundleId) {
50
52
  if (!(universal || example) && !["macos", "windows"].includes(platform))
51
53
  throw new Error("Use create --universal for mobile/web targets");
52
54
  archiveManifest ??= creationManifest();
@@ -73,7 +75,8 @@ export async function create(root, archiveManifest, platform = hostPlatform(), u
73
75
  overrides[name] = file;
74
76
  if (pkg.dependencies[name])
75
77
  pkg.dependencies[name] = file;
76
- if (pkg.allowScripts?.[name])
78
+ // Spark itself comes from the registry as a bare version, which npm would read as a package name.
79
+ if (pkg.allowScripts?.[name] && file.startsWith("file:"))
77
80
  pkg.allowScripts[file] = true;
78
81
  }
79
82
  applyOverrides(pkg, overrides, manager);
@@ -94,7 +97,7 @@ export async function create(root, archiveManifest, platform = hostPlatform(), u
94
97
  // Expo needs file: to distinguish Windows drive paths from npm package names.
95
98
  const child = spawnProcess(nodeCommand(path.resolve(import.meta.dirname, ".."), "expo-desktop", "expo-desktop", [
96
99
  "create-app", root, "--template", `file:${templateFile}`, "--yes", "--no-agents-md",
97
- "--display-name", name, "--rdns", `so.legend.spark.prototype.${name.toLowerCase()}`, ...(pnp ? ["--no-install"] : []),
100
+ "--display-name", name, "--rdns", bundleId ?? exampleBundleId(name), ...(pnp ? ["--no-install"] : []),
98
101
  ]), { cwd: process.cwd(), env: { ...process.env, PATH: `${npmBin}${path.delimiter}${process.env.PATH ?? ""}`, npm_config_user_agent: `${manager}/spark`, CI: "1", ...(pnp ? { NODE_OPTIONS: `${process.env.NODE_OPTIONS ?? ""} ${pnpWriteFile}` } : {}), ...(manager === "yarn" ? { YARN_ENABLE_IMMUTABLE_INSTALLS: "false" } : {}) }, stdout: "pipe", stderr: "inherit" });
99
102
  // Spark owns the next steps; Expo's final block requires an unnecessary prebuild.
100
103
  let projectReady = false;
@@ -141,7 +144,8 @@ export async function create(root, archiveManifest, platform = hostPlatform(), u
141
144
  }
142
145
  await configureExample(root, example);
143
146
  }
144
- console.log(`Created ${root}.\n\n cd ${JSON.stringify(root)}\n ${manager} run ${platform}`);
147
+ const rename = bundleId || variant === "windows" ? "" : `\n\nBefore you ship, change bundleIdentifier in desktop.config.json from ${exampleBundleId(path.basename(root))} to an ID you own.`;
148
+ console.log(`Created ${root}.\n\n cd ${JSON.stringify(root)}\n ${manager} run ${platform}${rename}`);
145
149
  }
146
150
  export function upgradeManagedEntry(root) {
147
151
  const oldMetro = `const { makeMetroConfig } = require("expo-desktop-metro-config");
@@ -1,12 +1,56 @@
1
1
  import { overridePackageName } from "./package-manager.js";
2
- import { readFileSync, writeFileSync } from "node:fs";
2
+ import { existsSync, readFileSync, readdirSync, writeFileSync } from "node:fs";
3
3
  import path from "node:path";
4
+ import { createRequire } from "node:module";
4
5
  import ts from "typescript";
5
6
  import { supportedPlatforms } from "@legendapp/spark-desktop-config/config.cjs";
6
7
  const packages = ["react", "react-native", "react-native-macos", "expo"];
7
8
  // create/refreshLocalPackages use this starter's tested compatibility matrix too.
8
9
  const defaults = JSON.parse(readFileSync(new URL("../templates/blank-typescript/package.json", import.meta.url), "utf8"));
9
10
  export const expectedDependencyPins = Object.fromEntries(packages.map(name => [name, defaults.dependencies[name]]));
11
+ /** Optional feature backends belong to the app, even when Spark supplies the API. */
12
+ export function optionalBackendIssues(root) {
13
+ const backends = {
14
+ "@legendapp/spark/markdown": "react-native-enriched-markdown",
15
+ "@legendapp/spark/html": "react-native-enriched-html",
16
+ "@legendapp/spark/webview": "react-native-webview",
17
+ "@legendapp/spark/sqlite": "@op-engineering/op-sqlite",
18
+ };
19
+ const pkg = JSON.parse(readFileSync(path.join(root, "package.json"), "utf8"));
20
+ const dependencies = { ...pkg.dependencies, ...pkg.devDependencies, ...pkg.optionalDependencies };
21
+ const platforms = supportedPlatforms(root);
22
+ const req = createRequire(path.join(root, "package.json"));
23
+ const issues = new Map();
24
+ function visit(directory) {
25
+ for (const entry of readdirSync(directory, { withFileTypes: true })) {
26
+ const file = path.join(directory, entry.name);
27
+ if (entry.isDirectory() && !["node_modules", ".git", ".spark", "spark-packages", "build", "dist", "Pods"].includes(entry.name))
28
+ visit(file);
29
+ else if (entry.isFile() && /\.[cm]?[jt]sx?$/.test(file)) {
30
+ const suffix = /\.(ios|android|macos|windows|web|native|desktop)\.[cm]?[jt]sx?$/.exec(entry.name)?.[1];
31
+ if (suffix && !platforms.some(platform => suffix === platform || (suffix === "native" && platform !== "web") || (suffix === "desktop" && ["macos", "windows"].includes(platform))))
32
+ continue;
33
+ const source = readFileSync(file, "utf8");
34
+ if (!source.includes("@legendapp/spark/"))
35
+ continue;
36
+ for (const imported of ts.preProcessFile(source, true, true).importedFiles) {
37
+ const name = backends[imported.fileName];
38
+ if (!name || issues.has(name))
39
+ continue;
40
+ const installed = req.resolve.paths(name)?.some(base => existsSync(path.join(base, name, "package.json")));
41
+ if (!dependencies[name] || !installed)
42
+ issues.set(name, {
43
+ package: name, found: dependencies[name] ? "(not installed)" : "(not declared)",
44
+ expected: defaults.overrides[name], missing: true,
45
+ where: ["dependencies", name, `Install for ${imported.fileName} in ${path.relative(root, file)}${["react-native-webview", "@op-engineering/op-sqlite"].includes(name) ? ", keeping the SDK archive override (spark upgrade)" : ""}`],
46
+ });
47
+ }
48
+ }
49
+ }
50
+ }
51
+ visit(root);
52
+ return [...issues.values()];
53
+ }
10
54
  export function dependencyPinIssues(pkg, platforms, expected = expectedDependencyPins) {
11
55
  const required = [...packages, ...(expected["@legendapp/spark"] ? ["@legendapp/spark"] : [])].filter(name => name !== "react-native-macos" || platforms.includes("macos"));
12
56
  const checked = Object.keys(expected).filter(name => name !== "react-native-macos" || platforms.includes("macos"));
@@ -13,6 +13,7 @@ import { createRequire } from "node:module";
13
13
  const { preparePatch } = createRequire(import.meta.url)("./expo-dev-patch.cjs");
14
14
  import { findGo, readRuntime, registerRuntime } from "./local.js";
15
15
  import { sessionStatus } from "./session-status.js";
16
+ import { watchmanStalls } from "./watchman.js";
16
17
  import { assertNativePatchPreflight } from "./native-patch-preflight.js";
17
18
  import { prepareConfig, dependencyStamp, goConfigurationIssues, incompatible, nativePackages, readJson, projectEnvironment, runtimeFor, stateFile, writeJson, } from "./project.js";
18
19
  export async function launch(root, app, port, options = {}) {
@@ -78,7 +79,10 @@ export async function dev(root, goApp, expoArgs = [], noOpen = false, appArgs =
78
79
  let restartPending = false;
79
80
  let reopenPending = false;
80
81
  let closing = false;
82
+ // Without --no-open the session opens the desktop app itself, so a missing Runner downloads without a keypress.
83
+ let autoOpen = !noOpen;
81
84
  let metro;
85
+ let skipWatchman;
82
86
  let finish;
83
87
  const finished = new Promise((resolve) => {
84
88
  finish = resolve;
@@ -93,6 +97,11 @@ export async function dev(root, goApp, expoArgs = [], noOpen = false, appArgs =
93
97
  }
94
98
  if (closing)
95
99
  return;
100
+ if (skipWatchman === undefined) {
101
+ skipWatchman = await watchmanStalls(root);
102
+ if (skipWatchman)
103
+ console.warn("Watchman is not responding, so Metro will scan files without it this session. To fix Watchman, run: watchman watch-del-all && watchman shutdown-server");
104
+ }
96
105
  let ready;
97
106
  const started = new Promise(resolve => { ready = resolve; });
98
107
  const [, expo, ...args] = nodeCommand(root, "expo", "expo", [
@@ -103,7 +112,7 @@ export async function dev(root, goApp, expoArgs = [], noOpen = false, appArgs =
103
112
  const child = spawnProcess([
104
113
  "node", "--require", path.join(import.meta.dirname, "expo-dev-preload.cjs"), expo, ...args,
105
114
  ], {
106
- cwd: root, env: { ...process.env, SPARK_PLATFORM: platform, SPARK_DEV_SESSION: "1" },
115
+ cwd: root, env: { ...process.env, SPARK_PLATFORM: platform, SPARK_DEV_SESSION: "1", ...(skipWatchman ? { SPARK_METRO_NO_WATCHMAN: "1" } : {}) },
107
116
  stdin: "inherit", stdout: "inherit", stderr: "inherit", serialization: "json",
108
117
  ipc(message, sender) {
109
118
  if (message?.type === "spark:ready") {
@@ -204,7 +213,8 @@ export async function dev(root, goApp, expoArgs = [], noOpen = false, appArgs =
204
213
  }
205
214
  issues.push(...goConfigurationIssues(readAppConfig(root)));
206
215
  }
207
- const view = sessionStatus(target, !!current, issues, appProcess?.exitCode === null, !!installedRelease()?.runners[`${platform}-${architecture(platform)}`]);
216
+ const asset = installedRelease()?.runners[`${platform}-${architecture(platform)}`];
217
+ const view = sessionStatus(target, !!current, issues, appProcess?.exitCode === null, asset ? { auto: autoOpen, size: asset.size } : false);
208
218
  if (view.compatible && current && appProcess?.exitCode === null &&
209
219
  (launchedRuntime?.app !== current.app || launchedRuntime.fingerprint !== current.runtime.fingerprint)) {
210
220
  // Discovery can find a different compatible binary after a native edit.
@@ -241,6 +251,7 @@ export async function dev(root, goApp, expoArgs = [], noOpen = false, appArgs =
241
251
  return view.compatible;
242
252
  }
243
253
  async function open() {
254
+ autoOpen = true;
244
255
  if (platform === "windows" ? process.platform !== "win32" : process.platform !== "darwin") {
245
256
  throw new Error(`Open ${platform} on a matching desktop host. Mobile and web remain available.`);
246
257
  }
@@ -14,11 +14,11 @@ export async function configureExample(root, example) {
14
14
  const desktop = suffixes.map(name => name === "desktop" ? "@legendapp/spark" : `@legendapp/spark-${name}`);
15
15
  if (!pkg.dependencies["@legendapp/spark"])
16
16
  throw new Error("SDK example requires @legendapp/spark");
17
- Object.assign(pkg.dependencies, { "expo-document-picker": "14.0.8", "expo-file-system": "19.0.24", "expo-sharing": "14.0.8" });
17
+ Object.assign(pkg.dependencies, { "expo-document-picker": "55.0.17", "expo-file-system": "55.0.26", "expo-sharing": "55.0.25" });
18
18
  if (example !== "document-editor")
19
19
  pkg.dependencies["@react-native-async-storage/async-storage"] = "2.2.0";
20
20
  if (example === "music-lite")
21
- pkg.dependencies["expo-audio"] = pkg.dependencies["expo-audio"] ?? pkg.overrides?.["expo-audio"] ?? pkg.resolutions?.["expo-audio"] ?? pkg.pnpm?.overrides?.["expo-audio"] ?? "1.1.1";
21
+ pkg.dependencies["expo-audio"] = pkg.dependencies["expo-audio"] ?? pkg.overrides?.["expo-audio"] ?? pkg.resolutions?.["expo-audio"] ?? pkg.pnpm?.overrides?.["expo-audio"] ?? "55.0.18";
22
22
  if (example === "diff-lite")
23
23
  pkg.dependencies["diff"] = "8.0.2";
24
24
  writeJson(path.join(root, "package.json"), pkg);
@@ -3,18 +3,18 @@ const path = require('node:path');
3
3
  const { createRequire } = require('node:module');
4
4
  const { createHash } = require('node:crypto');
5
5
 
6
- const VERSION = '54.0.27';
6
+ const VERSION = '55.0.37';
7
7
  const extension = JSON.stringify(path.join(__dirname, 'expo-dev-extension.cjs'));
8
8
  // Process-local patches: installed Expo files remain untouched. Verify the exact
9
9
  // upstream inputs before starting, so an Expo upgrade cannot silently lose keys.
10
10
  const patches = [
11
- ['interface/commandsTable.js', 'eeb1700b0ae26613bf6dedab556479a4c15d3a3c94c63ecbb5db21c4899e1645',
11
+ ['interface/commandsTable.js', '6d809faa4721fd68e86af40372e6aef7f729902afc1a1484f66cade067db4792',
12
12
  'function logCommandsTable(ui) {',
13
13
  `function logCommandsTable(ui) {\n ui = require(${extension}).integrateCommands(ui);`],
14
14
  ['interface/startInterface.js', 'c8e55431b18a37e1ab2be22f068c980e9cc41ffc105ea7478e34fc11b91a22bd',
15
15
  ' const onPressAsync = async (key)=>{',
16
16
  ` const onPressAsync = async (key)=>{\n try {\n if (await require(${extension}).handleKey(key)) return;\n } catch (error) {\n _log.exception(error);\n return;\n }`],
17
- ['startAsync.js', '0e062078e63ad6264b1393d403ad56d65a38c6430d30fdac50cd656486cd418b',
17
+ ['startAsync.js', 'fb52b3bd7962ad13c57c1a6e4050c9cc1420197186df7d0259d74ddbd79ae46b',
18
18
  ' await (0, _profile.profile)(devServerManager.startAsync.bind(devServerManager))(startOptions);',
19
19
  // Dependency validation can wait on the network after Metro is listening.
20
20
  // Report actual server readiness before those optional startup checks.
@@ -6,6 +6,9 @@ const { preparePatch } = require('./expo-dev-patch.cjs');
6
6
  if (!process.env.SPARK_EXPO_PRELOADED) {
7
7
  process.env.SPARK_EXPO_PRELOADED = '1';
8
8
  if (!process.send) throw new Error('Start the Spark Expo integration through spark dev.');
9
+ // Expo 55 binds --localhost to "localhost", which Node resolves to ::1 first;
10
+ // desktop runtimes and Spark's Metro clients connect to 127.0.0.1.
11
+ require('node:dns').setDefaultResultOrder('ipv4first');
9
12
  const patches = preparePatch(process.cwd());
10
13
  const load = Module._extensions['.js'];
11
14
  Module._extensions['.js'] = function(module, filename) {
@@ -3,11 +3,12 @@ import { publishCustomize } from "./customize-artifacts.js";
3
3
  import { nodeCommand, spawnProcess } from "./process.js";
4
4
  import { examples } from "./examples.js";
5
5
  import { prepareGoProfile } from "./go-profile.js";
6
+ import { mirrorRunner, preservedBuildState, releaseRunnerRoot, releaseRunnerStaging, rewritePathRecords, syncTree } from "./release-runner-root.js";
6
7
  import { exportSDK, importSDK } from "./sdk-transfer.js";
7
8
  import { hostPlatform } from "./platform.js";
8
9
  import path from "node:path";
9
10
  import { cliArguments } from "./cli-arguments.js";
10
- import { existsSync, readFileSync, writeFileSync } from "node:fs";
11
+ import { existsSync, readFileSync, rmSync, writeFileSync } from "node:fs";
11
12
  import { prepareConfig, readConfig, isExpoProject } from "@legendapp/spark-desktop-config/config.cjs";
12
13
  import { prepareWindows } from "./windows.js";
13
14
  import { create, refreshLocalPackages } from "./create.js";
@@ -22,7 +23,7 @@ import { doctor, run } from "./commands.js";
22
23
  import { findFramework, findProject, sparkHome, creationManifest, packageManifest, registerRuntime } from "./local.js";
23
24
  import { readJson, stateFile, VERSION, writeJson } from "./project.js";
24
25
  import { devCommand } from "./dev-command.js";
25
- import { printDependencyPins, upgradeDependencyPins } from "./dependency-pins.js";
26
+ import { optionalBackendIssues, printDependencyPins, upgradeDependencyPins } from "./dependency-pins.js";
26
27
  import { upgrade } from "./upgrade.js";
27
28
  import { ensureProjectVersion } from "./project-version.js";
28
29
  import { reportError } from "./errors.js";
@@ -96,7 +97,7 @@ Windows: dev and build --dev; production builds are not yet supported.
96
97
  SDK transfer: sdk export <directory> [--runtime <Spark Runner directory>], sdk import <directory>
97
98
  SDK maintainers: sdk pack, sdk package-runner, sdk build-runner [--platform windows], sdk register <runtime directory>
98
99
  Targets: dev/build/prebuild --platform macos|windows|ios|android|web
99
- Overrides: --project <directory>, --port <number>, dev --runner-binary <runtime path>, create --packages <manifest>, create / sdk build-runner --package-manager npm|pnpm|yarn|bun`);
100
+ Overrides: --project <directory>, --port <number>, dev --runner-binary <runtime path>, create --packages <manifest>, create --bundle-id <com.yourcompany.app>, create / sdk build-runner --package-manager npm|pnpm|yarn|bun`);
100
101
  }
101
102
  else
102
103
  switch (command) {
@@ -109,7 +110,7 @@ Overrides: --project <directory>, --port <number>, dev --runner-binary <runtime
109
110
  case "create": {
110
111
  if (!positionals[1])
111
112
  throw new Error("Usage: spark create MyApp");
112
- await create(path.resolve(positionals[1]), creationManifest(values.packages), platform, !!values.universal || !!values.example, values.example, values["package-manager"]);
113
+ await create(path.resolve(positionals[1]), creationManifest(values.packages), platform, !!values.universal || !!values.example, values.example, values["package-manager"], values["bundle-id"]);
113
114
  break;
114
115
  }
115
116
  case "sdk": {
@@ -153,14 +154,20 @@ Overrides: --project <directory>, --port <number>, dev --runner-binary <runtime
153
154
  }
154
155
  case "build-runner": {
155
156
  let root;
157
+ // Release builds (set by scripts/release-runner.ts) build macOS in one fixed folder so
158
+ // Xcode stays incremental across versions; users' builds are unchanged.
159
+ const fixedRoot = !projectOption && platform === "macos" && process.env.SPARK_RELEASE_FIXED_RUNNER === "1";
160
+ const versionRoot = path.join(sparkHome(), "sdk-builds", VERSION, ...(platform === "windows" ? ["windows"] : []), "SparkRunner");
156
161
  if (projectOption)
157
162
  root = project();
158
163
  else {
159
- root = path.join(sparkHome(), "sdk-builds", VERSION, ...(platform === "windows" ? ["windows"] : []), "SparkRunner");
164
+ root = fixedRoot ? releaseRunnerStaging(path.join(sparkHome(), "sdk-builds")) : versionRoot;
165
+ if (fixedRoot)
166
+ rmSync(root, { recursive: true, force: true });
160
167
  const manifest = packageManifest(values.packages);
161
168
  const manager = values["package-manager"];
162
169
  if (!existsSync(path.join(root, "package.json")))
163
- await create(root, manifest, platform, false, undefined, manager);
170
+ await create(root, manifest, platform, false, undefined, manager, "so.legend.spark.prototype.sparkrunner");
164
171
  else
165
172
  await refreshLocalPackages(root, manifest, manager);
166
173
  await prepareGoProfile(root, manifest, platform, manager);
@@ -168,8 +175,20 @@ Overrides: --project <directory>, --port <number>, dev --runner-binary <runtime
168
175
  const config = readJson(configFile);
169
176
  config.version = VERSION.split("-")[0];
170
177
  writeJson(configFile, config);
178
+ if (fixedRoot) {
179
+ const fixed = releaseRunnerRoot(path.join(sparkHome(), "sdk-builds"));
180
+ const changed = syncTree(root, fixed, preservedBuildState);
181
+ rewritePathRecords(fixed, root, fixed);
182
+ console.log(`Release Runner: building in ${fixed} (${changed.length} project files changed since the last release build).`);
183
+ rmSync(root, { recursive: true, force: true });
184
+ root = fixed;
185
+ }
171
186
  }
172
187
  await build(root, "go", !!values.force);
188
+ if (fixedRoot) {
189
+ mirrorRunner(root, versionRoot);
190
+ console.log(`Release Runner copied to ${versionRoot}.`);
191
+ }
173
192
  break;
174
193
  }
175
194
  default: throw new Error("SDK commands: spark sdk pack, spark sdk build-runner, spark sdk register <runtime directory>");
@@ -193,7 +212,7 @@ Overrides: --project <directory>, --port <number>, dev --runner-binary <runtime
193
212
  if (root) {
194
213
  ensureProjectVersion(root);
195
214
  try {
196
- const issues = [...upgradeDependencyPins(root, true), ...enrichedHtmlPinIssues(root)];
215
+ const issues = [...upgradeDependencyPins(root, true), ...enrichedHtmlPinIssues(root), ...optionalBackendIssues(root)];
197
216
  printDependencyPins(issues);
198
217
  if (issues.length) {
199
218
  process.exitCode = 1;
@@ -27,7 +27,9 @@ function withDesktop(config, options = {}) {
27
27
  for (const platform of ["macos", "windows"]) {
28
28
  conditions[platform] = [...new Set([...(conditions[platform] || []), "react-native"])];
29
29
  }
30
- config = { ...config, resolver: { ...config.resolver, unstable_conditionsByPlatform: conditions } };
30
+ config = { ...config, resolver: { ...config.resolver, unstable_conditionsByPlatform: conditions,
31
+ // spark dev found Watchman unresponsive; crawl and watch with Node instead.
32
+ ...(process.env.SPARK_METRO_NO_WATCHMAN === "1" ? { useWatchman: false } : {}) } };
31
33
  const root = path.resolve(config.projectRoot || process.cwd());
32
34
  // Keep the configured workspace root so lazy imports outside the app have
33
35
  // valid URLs. Only the prebuilt host's fixed entry URLs are app-relative.