expo-desktop 0.1.35 → 0.1.36
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.
|
@@ -1,34 +1,18 @@
|
|
|
1
1
|
import { createRequire } from "node:module";
|
|
2
|
-
import * as path from "node:path";
|
|
3
2
|
import { withInternal } from "./with-internal.js";
|
|
4
3
|
const require = createRequire(import.meta.url);
|
|
5
4
|
const { getPrebuildConfigAsync } = require("expo-desktop-prebuild-config");
|
|
6
5
|
const { compileModsAsync } = require("expo-desktop-config-plugins");
|
|
6
|
+
// These are subdependencies of expo-desktop-prebuild-config.
|
|
7
|
+
const { getConfig } = require("@expo/config");
|
|
8
|
+
const { withPlugins } = require("@expo/config-plugins");
|
|
7
9
|
/**
|
|
8
10
|
* Applies config plugins.
|
|
9
11
|
* @see https://github.com/microsoft/react-native-test-app/blob/trunk/packages/app/scripts/config-plugins/apply.mjs
|
|
10
12
|
*/
|
|
11
13
|
export async function applyConfigPlugins(options) {
|
|
12
14
|
const { projectRoot } = options;
|
|
13
|
-
//
|
|
14
|
-
// on an Expo 55 project, we import Expo deps from the project itself.
|
|
15
|
-
let expoConfigModule;
|
|
16
|
-
try {
|
|
17
|
-
expoConfigModule = require(path.dirname(require.resolve("@expo/config/package.json", { paths: [projectRoot] })));
|
|
18
|
-
}
|
|
19
|
-
catch (cause) {
|
|
20
|
-
throw new Error(`Error importing "@expo/config" relative to projectRoot "${projectRoot}". Make sure to install node modules before running any prebuilds, and make sure that the project depends on the package named "expo".`, { cause });
|
|
21
|
-
}
|
|
22
|
-
const { getConfig } = expoConfigModule;
|
|
23
|
-
let expoConfigPluginsModule;
|
|
24
|
-
try {
|
|
25
|
-
expoConfigPluginsModule = require(path.dirname(require.resolve("@expo/config-plugins/package.json", { paths: [projectRoot] })));
|
|
26
|
-
}
|
|
27
|
-
catch (cause) {
|
|
28
|
-
throw new Error(`Error importing "@expo/config-plugins" relative to projectRoot "${projectRoot}". Make sure to install node modules before running any prebuilds, and make sure that the project depends on the package named "expo".`, { cause });
|
|
29
|
-
}
|
|
30
|
-
const { withPlugins } = expoConfigPluginsModule;
|
|
31
|
-
// (1) Filter out platforms that aren't in the app.json.
|
|
15
|
+
// Filter out platforms that aren't in the app.json.
|
|
32
16
|
// https://github.com/expo/expo/blob/8dd645080f52927e2a8bf406167da7241a1d46d8/packages/%40expo/cli/src/prebuild/prebuildAsync.ts#L74
|
|
33
17
|
let { exp: expoConfig } = getConfig(projectRoot);
|
|
34
18
|
const { platforms, plugins } = expoConfig;
|
|
@@ -747,6 +747,10 @@ const require = createRequire(import.meta.url);
|
|
|
747
747
|
const { getPrebuildConfigAsync } = require("expo-desktop-prebuild-config");
|
|
748
748
|
const { compileModsAsync } = require("expo-desktop-config-plugins");
|
|
749
749
|
|
|
750
|
+
// These are subdependencies of expo-desktop-prebuild-config.
|
|
751
|
+
const { getConfig } = require("@expo/config");
|
|
752
|
+
const { withPlugins } = require("@expo/config-plugins");
|
|
753
|
+
|
|
750
754
|
const projectRoot = import.meta.dirname;
|
|
751
755
|
|
|
752
756
|
const info = {
|
|
@@ -789,33 +793,7 @@ const withInternal = (config, internals) => {
|
|
|
789
793
|
async function applyConfigPlugins(options) {
|
|
790
794
|
const { projectRoot } = options;
|
|
791
795
|
|
|
792
|
-
//
|
|
793
|
-
// on an Expo 55 project, we import Expo deps from the project itself.
|
|
794
|
-
/** @type {typeof import("@expo/config")} */
|
|
795
|
-
let expoConfigModule;
|
|
796
|
-
try {
|
|
797
|
-
expoConfigModule = require("@expo/config");
|
|
798
|
-
} catch (cause) {
|
|
799
|
-
throw new Error(
|
|
800
|
-
\`Error importing "@expo/config" relative to projectRoot "\${projectRoot}". Make sure to install node modules before running any prebuilds, and make sure that the project depends on the package named "expo".\`,
|
|
801
|
-
{ cause },
|
|
802
|
-
);
|
|
803
|
-
}
|
|
804
|
-
const { getConfig } = expoConfigModule;
|
|
805
|
-
|
|
806
|
-
/** @type {typeof import("@expo/config-plugins")} */
|
|
807
|
-
let expoConfigPluginsModule;
|
|
808
|
-
try {
|
|
809
|
-
expoConfigPluginsModule = require("@expo/config-plugins");
|
|
810
|
-
} catch (cause) {
|
|
811
|
-
throw new Error(
|
|
812
|
-
\`Error importing "@expo/config-plugins" relative to projectRoot "\${projectRoot}". Make sure to install node modules before running any prebuilds, and make sure that the project depends on the package named "expo".\`,
|
|
813
|
-
{ cause },
|
|
814
|
-
);
|
|
815
|
-
}
|
|
816
|
-
const { withPlugins } = expoConfigPluginsModule;
|
|
817
|
-
|
|
818
|
-
// (1) Filter out platforms that aren't in the app.json.
|
|
796
|
+
// Filter out platforms that aren't in the app.json.
|
|
819
797
|
// https://github.com/expo/expo/blob/8dd645080f52927e2a8bf406167da7241a1d46d8/packages/%40expo/cli/src/prebuild/prebuildAsync.ts#L74
|
|
820
798
|
let { exp: expoConfig } = getConfig(projectRoot);
|
|
821
799
|
const { platforms, plugins } = expoConfig;
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "expo-desktop",
|
|
3
|
-
"version": "0.1.
|
|
3
|
+
"version": "0.1.36",
|
|
4
4
|
"description": "Best-effort desktop support for Expo",
|
|
5
5
|
"keywords": [
|
|
6
6
|
"android",
|
|
@@ -37,8 +37,8 @@
|
|
|
37
37
|
"@clack/prompts": "^1.2.0",
|
|
38
38
|
"arktype": "^2.2.0",
|
|
39
39
|
"citty": "^0.2.2",
|
|
40
|
-
"expo-desktop-config-plugins": "^1.1.
|
|
41
|
-
"expo-desktop-prebuild-config": "^1.0.
|
|
40
|
+
"expo-desktop-config-plugins": "^1.1.33",
|
|
41
|
+
"expo-desktop-prebuild-config": "^1.0.19",
|
|
42
42
|
"glob": "^10.5.0",
|
|
43
43
|
"kleur": "^4.1.5",
|
|
44
44
|
"mustache": "^4.2.0",
|
|
@@ -46,18 +46,14 @@
|
|
|
46
46
|
"toml": "^4.1.1"
|
|
47
47
|
},
|
|
48
48
|
"devDependencies": {
|
|
49
|
-
"@expo/config": "^
|
|
50
|
-
"@expo/config-plugins": "^
|
|
49
|
+
"@expo/config": "^56.0.9",
|
|
50
|
+
"@expo/config-plugins": "^56.0.8",
|
|
51
51
|
"@tsconfig/node24": "^24.0.4",
|
|
52
52
|
"@types/mustache": "^4.2.6",
|
|
53
53
|
"@types/node": "^24.12.2",
|
|
54
54
|
"@typescript/native-preview": "^7.0.0-dev.20260425.1",
|
|
55
55
|
"vitest": "^3.2.4"
|
|
56
56
|
},
|
|
57
|
-
"peerDependencies": {
|
|
58
|
-
"@expo/config": ">=12.0.0",
|
|
59
|
-
"@expo/config-plugins": ">=54.0.0"
|
|
60
|
-
},
|
|
61
57
|
"lint-staged": {
|
|
62
58
|
"scripts/update-schema.ts": [
|
|
63
59
|
"node --run schema",
|