@nx/expo 23.0.0-beta.2 → 23.0.0-beta.20

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 (79) hide show
  1. package/migrations.json +1 -1
  2. package/package.json +8 -8
  3. package/plugins/metro-resolver.js +2 -2
  4. package/plugins/plugin.d.ts.map +1 -1
  5. package/plugins/plugin.js +65 -39
  6. package/src/executors/build/build.impl.d.ts.map +1 -1
  7. package/src/executors/build/build.impl.js +2 -0
  8. package/src/executors/build/schema.json +1 -0
  9. package/src/executors/export/export.impl.d.ts.map +1 -1
  10. package/src/executors/export/export.impl.js +2 -0
  11. package/src/executors/export/schema.json +1 -0
  12. package/src/executors/install/install.impl.d.ts.map +1 -1
  13. package/src/executors/install/install.impl.js +2 -0
  14. package/src/executors/install/schema.json +1 -0
  15. package/src/executors/prebuild/prebuild.impl.d.ts.map +1 -1
  16. package/src/executors/prebuild/prebuild.impl.js +2 -0
  17. package/src/executors/prebuild/schema.json +1 -0
  18. package/src/executors/run/run.impl.d.ts.map +1 -1
  19. package/src/executors/run/run.impl.js +2 -0
  20. package/src/executors/run/schema.json +1 -0
  21. package/src/executors/serve/schema.json +1 -0
  22. package/src/executors/serve/serve.impl.d.ts.map +1 -1
  23. package/src/executors/serve/serve.impl.js +2 -0
  24. package/src/executors/start/schema.json +1 -0
  25. package/src/executors/start/start.impl.d.ts.map +1 -1
  26. package/src/executors/start/start.impl.js +2 -0
  27. package/src/executors/submit/schema.json +1 -0
  28. package/src/executors/submit/submit.impl.d.ts.map +1 -1
  29. package/src/executors/submit/submit.impl.js +2 -0
  30. package/src/generators/application/application.d.ts.map +1 -1
  31. package/src/generators/application/application.js +7 -8
  32. package/src/generators/application/lib/add-e2e.d.ts.map +1 -1
  33. package/src/generators/application/lib/add-e2e.js +5 -5
  34. package/src/generators/application/lib/add-project.d.ts.map +1 -1
  35. package/src/generators/application/lib/add-project.js +4 -2
  36. package/src/generators/application/lib/normalize-options.js +5 -5
  37. package/src/generators/component/component.js +2 -2
  38. package/src/generators/component/lib/normalize-options.d.ts +2 -2
  39. package/src/generators/component/lib/normalize-options.d.ts.map +1 -1
  40. package/src/generators/component/lib/normalize-options.js +5 -6
  41. package/src/generators/component/schema.d.ts +0 -5
  42. package/src/generators/component/schema.json +0 -5
  43. package/src/generators/convert-to-inferred/convert-to-inferred.d.ts.map +1 -1
  44. package/src/generators/convert-to-inferred/convert-to-inferred.js +4 -5
  45. package/src/generators/convert-to-inferred/lib/post-target-transformer.d.ts +1 -1
  46. package/src/generators/convert-to-inferred/lib/post-target-transformer.d.ts.map +1 -1
  47. package/src/generators/convert-to-inferred/lib/post-target-transformer.js +2 -2
  48. package/src/generators/convert-to-inferred/lib/process-build-options.d.ts +1 -1
  49. package/src/generators/convert-to-inferred/lib/process-build-options.d.ts.map +1 -1
  50. package/src/generators/convert-to-inferred/lib/process-export-options.d.ts +1 -1
  51. package/src/generators/convert-to-inferred/lib/process-export-options.d.ts.map +1 -1
  52. package/src/generators/convert-to-inferred/lib/process-generic-options.d.ts +1 -1
  53. package/src/generators/convert-to-inferred/lib/process-generic-options.d.ts.map +1 -1
  54. package/src/generators/convert-to-inferred/lib/process-install-options.d.ts +1 -1
  55. package/src/generators/convert-to-inferred/lib/process-install-options.d.ts.map +1 -1
  56. package/src/generators/convert-to-inferred/lib/process-prebuild-options.d.ts +1 -1
  57. package/src/generators/convert-to-inferred/lib/process-prebuild-options.d.ts.map +1 -1
  58. package/src/generators/convert-to-inferred/lib/process-run-options.d.ts +1 -1
  59. package/src/generators/convert-to-inferred/lib/process-run-options.d.ts.map +1 -1
  60. package/src/generators/convert-to-inferred/lib/process-serve-options.d.ts +1 -1
  61. package/src/generators/convert-to-inferred/lib/process-serve-options.d.ts.map +1 -1
  62. package/src/generators/convert-to-inferred/lib/process-start-options.d.ts +1 -1
  63. package/src/generators/convert-to-inferred/lib/process-start-options.d.ts.map +1 -1
  64. package/src/generators/convert-to-inferred/lib/process-submit-options.d.ts +1 -1
  65. package/src/generators/convert-to-inferred/lib/process-submit-options.d.ts.map +1 -1
  66. package/src/generators/init/init.d.ts.map +1 -1
  67. package/src/generators/init/init.js +2 -2
  68. package/src/generators/library/lib/normalize-options.js +5 -5
  69. package/src/generators/library/library.d.ts.map +1 -1
  70. package/src/generators/library/library.js +9 -12
  71. package/src/utils/add-linting.js +9 -10
  72. package/src/utils/deprecation.d.ts +4 -0
  73. package/src/utils/deprecation.d.ts.map +1 -0
  74. package/src/utils/deprecation.js +23 -0
  75. package/src/utils/expo-project-detection.js +2 -2
  76. package/src/migrations/update-22-2-0/create-ai-instructions-for-expo-54.d.ts +0 -3
  77. package/src/migrations/update-22-2-0/create-ai-instructions-for-expo-54.d.ts.map +0 -1
  78. package/src/migrations/update-22-2-0/create-ai-instructions-for-expo-54.js +0 -16
  79. /package/src/migrations/update-22-2-0/{files/ai-instructions-for-expo-54.md → ai-instructions-for-expo-54.md} +0 -0
package/migrations.json CHANGED
@@ -22,7 +22,7 @@
22
22
  "version": "22.2.0-beta.3",
23
23
  "cli": "nx",
24
24
  "description": "Create AI migration instructions for Expo SDK 54 upgrade",
25
- "factory": "./src/migrations/update-22-2-0/create-ai-instructions-for-expo-54"
25
+ "prompt": "./src/migrations/update-22-2-0/ai-instructions-for-expo-54.md"
26
26
  },
27
27
  "update-22-2-0-add-expo-system-ui": {
28
28
  "version": "22.2.0-beta.3",
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@nx/expo",
3
- "version": "23.0.0-beta.2",
3
+ "version": "23.0.0-beta.20",
4
4
  "private": false,
5
5
  "description": "The Expo Plugin for Nx contains executors and generators for managing and developing an expo application within your workspace. For example, you can directly build for different target platforms as well as generate projects and publish your code.",
6
6
  "keywords": [
@@ -29,10 +29,10 @@
29
29
  "type": "commonjs",
30
30
  "types": "index.d.ts",
31
31
  "dependencies": {
32
- "@nx/devkit": "23.0.0-beta.2",
33
- "@nx/eslint": "23.0.0-beta.2",
34
- "@nx/js": "23.0.0-beta.2",
35
- "@nx/react": "23.0.0-beta.2",
32
+ "@nx/devkit": "23.0.0-beta.20",
33
+ "@nx/eslint": "23.0.0-beta.20",
34
+ "@nx/js": "23.0.0-beta.20",
35
+ "@nx/react": "23.0.0-beta.20",
36
36
  "enhanced-resolve": "^5.8.3",
37
37
  "picocolors": "^1.1.0",
38
38
  "semver": "^7.6.3",
@@ -44,11 +44,11 @@
44
44
  "metro-resolver": ">= 0.82.0"
45
45
  },
46
46
  "devDependencies": {
47
- "nx": "23.0.0-beta.2"
47
+ "nx": "23.0.0-beta.20"
48
48
  },
49
49
  "optionalDependencies": {
50
- "@nx/detox": "23.0.0-beta.2",
51
- "@nx/rollup": "23.0.0-beta.2"
50
+ "@nx/detox": "23.0.0-beta.20",
51
+ "@nx/rollup": "23.0.0-beta.20"
52
52
  },
53
53
  "executors": "./executors.json",
54
54
  "ng-update": {
@@ -3,7 +3,7 @@ Object.defineProperty(exports, "__esModule", { value: true });
3
3
  exports.getResolveRequest = getResolveRequest;
4
4
  const tslib_1 = require("tslib");
5
5
  const tsconfig_paths_1 = require("tsconfig-paths");
6
- const ts_config_1 = require("@nx/js/src/utils/typescript/ts-config");
6
+ const js_1 = require("@nx/js");
7
7
  const pc = tslib_1.__importStar(require("picocolors"));
8
8
  const enhanced_resolve_1 = require("enhanced-resolve");
9
9
  const path_1 = require("path");
@@ -120,7 +120,7 @@ function getMatcher(debug) {
120
120
  if (!matcher) {
121
121
  const result = (0, tsconfig_paths_1.loadConfig)();
122
122
  if (result.resultType === 'success') {
123
- absoluteBaseUrl = (0, ts_config_1.resolvePathsBaseUrl)(result.configFileAbsolutePath);
123
+ absoluteBaseUrl = (0, js_1.resolvePathsBaseUrl)(result.configFileAbsolutePath);
124
124
  paths = result.paths;
125
125
  if (debug) {
126
126
  console.log(pc.cyan(`[Nx] Located tsconfig at ${pc.bold(absoluteBaseUrl)}`));
@@ -1 +1 @@
1
- {"version":3,"file":"plugin.d.ts","sourceRoot":"","sources":["../../../../packages/expo/plugins/plugin.ts"],"names":[],"mappings":"AAAA,OAAO,EAIL,aAAa,EAOd,MAAM,YAAY,CAAC;AAWpB,MAAM,WAAW,iBAAiB;IAChC,eAAe,CAAC,EAAE,MAAM,CAAC;IACzB,eAAe,CAAC,EAAE,MAAM,CAAC;IACzB,gBAAgB,CAAC,EAAE,MAAM,CAAC;IAC1B,oBAAoB,CAAC,EAAE,MAAM,CAAC;IAC9B,gBAAgB,CAAC,EAAE,MAAM,CAAC;IAC1B,kBAAkB,CAAC,EAAE,MAAM,CAAC;IAC5B,iBAAiB,CAAC,EAAE,MAAM,CAAC;IAC3B,eAAe,CAAC,EAAE,MAAM,CAAC;IACzB,gBAAgB,CAAC,EAAE,MAAM,CAAC;IAC1B,mBAAmB,CAAC,EAAE,MAAM,CAAC;IAC7B,mBAAmB,CAAC,EAAE,MAAM,CAAC;CAC9B;AAsBD,eAAO,MAAM,WAAW,EAAE,aAAa,CAAC,iBAAiB,CAsBxD,CAAC;AAEF,eAAO,MAAM,aAAa,kCAAc,CAAC"}
1
+ {"version":3,"file":"plugin.d.ts","sourceRoot":"","sources":["../../../../packages/expo/plugins/plugin.ts"],"names":[],"mappings":"AAMA,OAAO,EAML,aAAa,EAMd,MAAM,YAAY,CAAC;AAQpB,MAAM,WAAW,iBAAiB;IAChC,eAAe,CAAC,EAAE,MAAM,CAAC;IACzB,eAAe,CAAC,EAAE,MAAM,CAAC;IACzB,gBAAgB,CAAC,EAAE,MAAM,CAAC;IAC1B,oBAAoB,CAAC,EAAE,MAAM,CAAC;IAC9B,gBAAgB,CAAC,EAAE,MAAM,CAAC;IAC1B,kBAAkB,CAAC,EAAE,MAAM,CAAC;IAC5B,iBAAiB,CAAC,EAAE,MAAM,CAAC;IAC3B,eAAe,CAAC,EAAE,MAAM,CAAC;IACzB,gBAAgB,CAAC,EAAE,MAAM,CAAC;IAC1B,mBAAmB,CAAC,EAAE,MAAM,CAAC;IAC7B,mBAAmB,CAAC,EAAE,MAAM,CAAC;CAC9B;AAID,eAAO,MAAM,WAAW,EAAE,aAAa,CAAC,iBAAiB,CA2DxD,CAAC;AAEF,eAAO,MAAM,aAAa,kCAAc,CAAC"}
package/plugins/plugin.js CHANGED
@@ -1,71 +1,68 @@
1
1
  "use strict";
2
2
  Object.defineProperty(exports, "__esModule", { value: true });
3
3
  exports.createNodesV2 = exports.createNodes = void 0;
4
+ const internal_1 = require("@nx/devkit/internal");
4
5
  const devkit_1 = require("@nx/devkit");
5
6
  const path_1 = require("path");
6
7
  const js_1 = require("@nx/js");
7
- const get_named_inputs_1 = require("@nx/devkit/src/utils/get-named-inputs");
8
8
  const fs_1 = require("fs");
9
- const calculate_hash_for_create_nodes_1 = require("@nx/devkit/src/utils/calculate-hash-for-create-nodes");
10
9
  const cache_directory_1 = require("nx/src/utils/cache-directory");
11
10
  const devkit_internals_1 = require("nx/src/devkit-internals");
12
- const config_utils_1 = require("@nx/devkit/src/utils/config-utils");
13
- const util_1 = require("@nx/js/src/plugins/typescript/util");
14
- function readTargetsCache(cachePath) {
15
- return (0, fs_1.existsSync)(cachePath) ? (0, devkit_1.readJsonFile)(cachePath) : {};
16
- }
17
- function writeTargetsToCache(cachePath, targetsCache) {
18
- const oldCache = readTargetsCache(cachePath);
19
- (0, devkit_1.writeJsonFile)(cachePath, {
20
- ...oldCache,
21
- targetsCache,
22
- });
23
- }
11
+ const internal_2 = require("@nx/js/internal");
24
12
  exports.createNodes = [
25
13
  '**/app.{json,config.js,config.ts}',
26
14
  async (configFiles, options, context) => {
27
15
  const optionsHash = (0, devkit_internals_1.hashObject)(options);
28
16
  const cachePath = (0, path_1.join)(cache_directory_1.workspaceDataDirectory, `expo-${optionsHash}.hash`);
29
- const targetsCache = readTargetsCache(cachePath);
30
- const pmc = (0, devkit_1.getPackageManagerCommand)((0, devkit_1.detectPackageManager)(context.workspaceRoot));
17
+ const targetsCache = new internal_1.PluginCache(cachePath);
18
+ const packageManager = (0, devkit_1.detectPackageManager)(context.workspaceRoot);
19
+ const pmc = (0, devkit_1.getPackageManagerCommand)(packageManager);
20
+ const lockFileName = (0, js_1.getLockFileName)(packageManager);
21
+ const normalizedOptions = normalizeOptions(options);
31
22
  try {
32
- return await (0, devkit_1.createNodesFromFiles)((configFile, options, context) => createNodesInternal(configFile, options, context, targetsCache, pmc), configFiles, options, context);
23
+ const { entries, preErrors } = await filterExpoConfigs(configFiles, context);
24
+ const projectHashes = await (0, internal_1.calculateHashesForCreateNodes)(entries.map((e) => e.projectRoot), normalizedOptions, context, entries.map(() => [lockFileName]));
25
+ let results = [];
26
+ let nodeErrors = [];
27
+ try {
28
+ results = await (0, devkit_1.createNodesFromFiles)((configFile, _, ctx, idx) => createNodesInternal(configFile, normalizedOptions, ctx, targetsCache, pmc, projectHashes[idx]), entries.map((e) => e.configFile), options, context);
29
+ }
30
+ catch (e) {
31
+ if (e instanceof devkit_1.AggregateCreateNodesError) {
32
+ results = e.partialResults ?? [];
33
+ nodeErrors = e.errors;
34
+ }
35
+ else {
36
+ throw e;
37
+ }
38
+ }
39
+ const allErrors = [...preErrors, ...nodeErrors];
40
+ if (allErrors.length > 0) {
41
+ throw new devkit_1.AggregateCreateNodesError(allErrors, results);
42
+ }
43
+ return results;
33
44
  }
34
45
  finally {
35
- writeTargetsToCache(cachePath, targetsCache);
46
+ targetsCache.writeToDisk();
36
47
  }
37
48
  },
38
49
  ];
39
50
  exports.createNodesV2 = exports.createNodes;
40
- async function createNodesInternal(configFile, options, context, targetsCache, pmc) {
41
- options = normalizeOptions(options);
51
+ async function createNodesInternal(configFile, options, context, targetsCache, pmc, hash) {
42
52
  const projectRoot = (0, path_1.dirname)(configFile);
43
- // Do not create a project if package.json or project.json or metro.config.js isn't there.
44
- const siblingFiles = (0, fs_1.readdirSync)((0, path_1.join)(context.workspaceRoot, projectRoot));
45
- if (!siblingFiles.includes('package.json') ||
46
- !siblingFiles.includes('metro.config.js')) {
47
- return {};
48
- }
49
- // Check if it's an Expo project
50
- const packageJson = (0, devkit_1.readJsonFile)((0, path_1.join)(context.workspaceRoot, projectRoot, 'package.json'));
51
- const appConfig = await getAppConfig(configFile, context);
52
- if (!appConfig.expo &&
53
- !packageJson.dependencies?.['expo'] &&
54
- !packageJson.devDependencies?.['expo']) {
55
- return {};
53
+ if (!targetsCache.has(hash)) {
54
+ targetsCache.set(hash, buildExpoTargets(projectRoot, options, context, pmc));
56
55
  }
57
- const hash = await (0, calculate_hash_for_create_nodes_1.calculateHashForCreateNodes)(projectRoot, options, context, [(0, js_1.getLockFileName)((0, devkit_1.detectPackageManager)(context.workspaceRoot))]);
58
- targetsCache[hash] ??= buildExpoTargets(projectRoot, options, context, pmc);
59
56
  return {
60
57
  projects: {
61
58
  [projectRoot]: {
62
- targets: targetsCache[hash],
59
+ targets: targetsCache.get(hash),
63
60
  },
64
61
  },
65
62
  };
66
63
  }
67
64
  function buildExpoTargets(projectRoot, options, context, pmc) {
68
- const namedInputs = (0, get_named_inputs_1.getNamedInputs)(projectRoot, context);
65
+ const namedInputs = (0, internal_1.getNamedInputs)(projectRoot, context);
69
66
  const targets = {
70
67
  [options.startTargetName]: {
71
68
  executor: `@nx/expo:start`,
@@ -108,12 +105,41 @@ function buildExpoTargets(projectRoot, options, context, pmc) {
108
105
  options: { cwd: projectRoot },
109
106
  },
110
107
  };
111
- (0, util_1.addBuildAndWatchDepsTargets)(context.workspaceRoot, projectRoot, targets, options, pmc);
108
+ (0, internal_2.addBuildAndWatchDepsTargets)(context.workspaceRoot, projectRoot, targets, options, pmc);
112
109
  return targets;
113
110
  }
114
111
  function getAppConfig(configFilePath, context) {
115
112
  const resolvedPath = (0, path_1.join)(context.workspaceRoot, configFilePath);
116
- return (0, config_utils_1.loadConfigFile)(resolvedPath);
113
+ return (0, internal_1.loadConfigFile)(resolvedPath);
114
+ }
115
+ async function filterExpoConfigs(configFiles, context) {
116
+ const preErrors = [];
117
+ const candidates = await Promise.all(configFiles.map(async (configFile) => {
118
+ try {
119
+ const projectRoot = (0, path_1.dirname)(configFile);
120
+ const siblingFiles = (0, fs_1.readdirSync)((0, path_1.join)(context.workspaceRoot, projectRoot));
121
+ if (!siblingFiles.includes('package.json') ||
122
+ !siblingFiles.includes('metro.config.js')) {
123
+ return null;
124
+ }
125
+ const packageJson = (0, devkit_1.readJsonFile)((0, path_1.join)(context.workspaceRoot, projectRoot, 'package.json'));
126
+ const appConfig = await getAppConfig(configFile, context);
127
+ if (!appConfig.expo &&
128
+ !packageJson.dependencies?.['expo'] &&
129
+ !packageJson.devDependencies?.['expo']) {
130
+ return null;
131
+ }
132
+ return { configFile, projectRoot };
133
+ }
134
+ catch (e) {
135
+ preErrors.push([configFile, e]);
136
+ return null;
137
+ }
138
+ }));
139
+ return {
140
+ entries: candidates.filter((c) => c !== null),
141
+ preErrors,
142
+ };
117
143
  }
118
144
  function getInputs(namedInputs) {
119
145
  return [
@@ -1 +1 @@
1
- {"version":3,"file":"build.impl.d.ts","sourceRoot":"","sources":["../../../../../../packages/expo/src/executors/build/build.impl.ts"],"names":[],"mappings":"AAAA,OAAO,EAEL,eAAe,EAMhB,MAAM,YAAY,CAAC;AAUpB,OAAO,EAAE,mBAAmB,EAAE,MAAM,UAAU,CAAC;AAE/C,MAAM,WAAW,sBAAsB;IACrC,OAAO,EAAE,OAAO,CAAC;CAClB;AAID,wBAA+B,aAAa,CAC1C,OAAO,EAAE,mBAAmB,EAC5B,OAAO,EAAE,eAAe,GACvB,cAAc,CAAC,sBAAsB,CAAC,CAqBxC"}
1
+ {"version":3,"file":"build.impl.d.ts","sourceRoot":"","sources":["../../../../../../packages/expo/src/executors/build/build.impl.ts"],"names":[],"mappings":"AAAA,OAAO,EAEL,eAAe,EAMhB,MAAM,YAAY,CAAC;AAWpB,OAAO,EAAE,mBAAmB,EAAE,MAAM,UAAU,CAAC;AAE/C,MAAM,WAAW,sBAAsB;IACrC,OAAO,EAAE,OAAO,CAAC;CAClB;AAID,wBAA+B,aAAa,CAC1C,OAAO,EAAE,mBAAmB,EAC5B,OAAO,EAAE,eAAe,GACvB,cAAc,CAAC,sBAAsB,CAAC,CAuBxC"}
@@ -8,8 +8,10 @@ const child_process_1 = require("child_process");
8
8
  const node_fs_1 = require("node:fs");
9
9
  const path_1 = require("path");
10
10
  const resolve_eas_1 = require("../../utils/resolve-eas");
11
+ const deprecation_1 = require("../../utils/deprecation");
11
12
  let childProcess;
12
13
  async function* buildExecutor(options, context) {
14
+ (0, deprecation_1.warnExpoExecutorDeprecation)('build');
13
15
  const projectRoot = context.projectsConfigurations.projects[context.projectName].root;
14
16
  let resetLocalFunction;
15
17
  try {
@@ -7,6 +7,7 @@
7
7
  "title": "Expo EAS Build executor",
8
8
  "description": "Start an EAS build for your expo project.",
9
9
  "type": "object",
10
+ "x-deprecated": "The `@nx/expo:build` executor is deprecated and will be removed in Nx v24. Run `nx g @nx/expo:convert-to-inferred` to migrate to the `@nx/expo/plugin` inferred plugin. See https://nx.dev/docs/guides/tasks--caching/convert-to-inferred for details.",
10
11
  "presets": [
11
12
  {
12
13
  "name": "Build for a specific platform",
@@ -1 +1 @@
1
- {"version":3,"file":"export.impl.d.ts","sourceRoot":"","sources":["../../../../../../packages/expo/src/executors/export/export.impl.ts"],"names":[],"mappings":"AAAA,OAAO,EACL,eAAe,EAIhB,MAAM,YAAY,CAAC;AAKpB,OAAO,EAAE,oBAAoB,EAAE,MAAM,UAAU,CAAC;AAEhD,MAAM,WAAW,gBAAgB;IAC/B,OAAO,EAAE,OAAO,CAAC;CAClB;AAID,wBAA+B,cAAc,CAC3C,OAAO,EAAE,oBAAoB,EAC7B,OAAO,EAAE,eAAe,GACvB,cAAc,CAAC,gBAAgB,CAAC,CAclC;AAqCD,wBAAgB,mBAAmB,CACjC,OAAO,EAAE,oBAAoB,EAC7B,WAAW,EAAE,MAAM,SA4BpB"}
1
+ {"version":3,"file":"export.impl.d.ts","sourceRoot":"","sources":["../../../../../../packages/expo/src/executors/export/export.impl.ts"],"names":[],"mappings":"AAAA,OAAO,EACL,eAAe,EAIhB,MAAM,YAAY,CAAC;AAKpB,OAAO,EAAE,oBAAoB,EAAE,MAAM,UAAU,CAAC;AAGhD,MAAM,WAAW,gBAAgB;IAC/B,OAAO,EAAE,OAAO,CAAC;CAClB;AAID,wBAA+B,cAAc,CAC3C,OAAO,EAAE,oBAAoB,EAC7B,OAAO,EAAE,eAAe,GACvB,cAAc,CAAC,gBAAgB,CAAC,CAgBlC;AAqCD,wBAAgB,mBAAmB,CACjC,OAAO,EAAE,oBAAoB,EAC7B,WAAW,EAAE,MAAM,SA4BpB"}
@@ -6,8 +6,10 @@ const devkit_1 = require("@nx/devkit");
6
6
  const internal_1 = require("@nx/devkit/internal");
7
7
  const child_process_1 = require("child_process");
8
8
  const path_1 = require("path");
9
+ const deprecation_1 = require("../../utils/deprecation");
9
10
  let childProcess;
10
11
  async function* exportExecutor(options, context) {
12
+ (0, deprecation_1.warnExpoExecutorDeprecation)('export');
11
13
  const projectRoot = context.projectsConfigurations.projects[context.projectName].root;
12
14
  try {
13
15
  await exportAsync(context.root, projectRoot, options);
@@ -7,6 +7,7 @@
7
7
  "title": "Expo Export",
8
8
  "description": "Export the JavaScript and assets for your app using Metro/webpack bundler.",
9
9
  "type": "object",
10
+ "x-deprecated": "The `@nx/expo:export` executor is deprecated and will be removed in Nx v24. Run `nx g @nx/expo:convert-to-inferred` to migrate to the `@nx/expo/plugin` inferred plugin. See https://nx.dev/docs/guides/tasks--caching/convert-to-inferred for details.",
10
11
  "properties": {
11
12
  "platform": {
12
13
  "description": "Choose the platform to compile for",
@@ -1 +1 @@
1
- {"version":3,"file":"install.impl.d.ts","sourceRoot":"","sources":["../../../../../../packages/expo/src/executors/install/install.impl.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,eAAe,EAAS,MAAM,YAAY,CAAC;AAIpD,OAAO,EAAE,kBAAkB,EAAE,MAAM,UAAU,CAAC;AAO9C,MAAM,WAAW,iBAAiB;IAChC,OAAO,EAAE,OAAO,CAAC;CAClB;AAID,wBAA+B,eAAe,CAC5C,OAAO,EAAE,kBAAkB,EAC3B,OAAO,EAAE,eAAe,GACvB,cAAc,CAAC,iBAAiB,CAAC,CAWnC;AAED,wBAAsB,2BAA2B,CAC/C,OAAO,EAAE,eAAe,EACxB,OAAO,EAAE,kBAAkB,iBAwC5B"}
1
+ {"version":3,"file":"install.impl.d.ts","sourceRoot":"","sources":["../../../../../../packages/expo/src/executors/install/install.impl.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,eAAe,EAAS,MAAM,YAAY,CAAC;AAIpD,OAAO,EAAE,kBAAkB,EAAE,MAAM,UAAU,CAAC;AAQ9C,MAAM,WAAW,iBAAiB;IAChC,OAAO,EAAE,OAAO,CAAC;CAClB;AAID,wBAA+B,eAAe,CAC5C,OAAO,EAAE,kBAAkB,EAC3B,OAAO,EAAE,eAAe,GACvB,cAAc,CAAC,iBAAiB,CAAC,CAanC;AAED,wBAAsB,2BAA2B,CAC/C,OAAO,EAAE,eAAe,EACxB,OAAO,EAAE,kBAAkB,iBAwC5B"}
@@ -6,8 +6,10 @@ const devkit_1 = require("@nx/devkit");
6
6
  const fileutils_1 = require("nx/src/utils/fileutils");
7
7
  const path_1 = require("path");
8
8
  const sync_deps_impl_1 = require("../sync-deps/sync-deps.impl");
9
+ const deprecation_1 = require("../../utils/deprecation");
9
10
  let childProcess;
10
11
  async function* installExecutor(options, context) {
12
+ (0, deprecation_1.warnExpoExecutorDeprecation)('install');
11
13
  try {
12
14
  await installAndUpdatePackageJson(context, options);
13
15
  yield {
@@ -7,6 +7,7 @@
7
7
  "title": "Expo Install",
8
8
  "description": "Install a module or other package to a project.",
9
9
  "type": "object",
10
+ "x-deprecated": "The `@nx/expo:install` executor is deprecated and will be removed in Nx v24. Run `nx g @nx/expo:convert-to-inferred` to migrate to the `@nx/expo/plugin` inferred plugin. See https://nx.dev/docs/guides/tasks--caching/convert-to-inferred for details.",
10
11
  "properties": {
11
12
  "packages": {
12
13
  "type": "array",
@@ -1 +1 @@
1
- {"version":3,"file":"prebuild.impl.d.ts","sourceRoot":"","sources":["../../../../../../packages/expo/src/executors/prebuild/prebuild.impl.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,eAAe,EAAwB,MAAM,YAAY,CAAC;AAMnE,OAAO,EAAE,mBAAmB,EAAE,MAAM,UAAU,CAAC;AAE/C,MAAM,WAAW,kBAAkB;IACjC,OAAO,EAAE,OAAO,CAAC;CAClB;AAID,wBAA+B,gBAAgB,CAC7C,OAAO,EAAE,mBAAmB,EAC5B,OAAO,EAAE,eAAe,GACvB,cAAc,CAAC,kBAAkB,CAAC,CAyBpC;AAED,wBAAgB,aAAa,CAC3B,aAAa,EAAE,MAAM,EACrB,WAAW,EAAE,MAAM,EACnB,OAAO,EAAE,mBAAmB,GAC3B,OAAO,CAAC,MAAM,CAAC,CA2BjB"}
1
+ {"version":3,"file":"prebuild.impl.d.ts","sourceRoot":"","sources":["../../../../../../packages/expo/src/executors/prebuild/prebuild.impl.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,eAAe,EAAwB,MAAM,YAAY,CAAC;AAMnE,OAAO,EAAE,mBAAmB,EAAE,MAAM,UAAU,CAAC;AAG/C,MAAM,WAAW,kBAAkB;IACjC,OAAO,EAAE,OAAO,CAAC;CAClB;AAID,wBAA+B,gBAAgB,CAC7C,OAAO,EAAE,mBAAmB,EAC5B,OAAO,EAAE,eAAe,GACvB,cAAc,CAAC,kBAAkB,CAAC,CA2BpC;AAED,wBAAgB,aAAa,CAC3B,aAAa,EAAE,MAAM,EACrB,WAAW,EAAE,MAAM,EACnB,OAAO,EAAE,mBAAmB,GAC3B,OAAO,CAAC,MAAM,CAAC,CA2BjB"}
@@ -7,8 +7,10 @@ const internal_1 = require("@nx/devkit/internal");
7
7
  const child_process_1 = require("child_process");
8
8
  const path_1 = require("path");
9
9
  const pod_install_task_1 = require("../../utils/pod-install-task");
10
+ const deprecation_1 = require("../../utils/deprecation");
10
11
  let childProcess;
11
12
  async function* prebuildExecutor(options, context) {
13
+ (0, deprecation_1.warnExpoExecutorDeprecation)('prebuild');
12
14
  const projectRoot = context.projectsConfigurations.projects[context.projectName].root;
13
15
  try {
14
16
  await prebuildAsync(context.root, projectRoot, options);
@@ -7,6 +7,7 @@
7
7
  "title": "Expo Prebuild",
8
8
  "description": "Create native iOS and Android project files for building natively.",
9
9
  "type": "object",
10
+ "x-deprecated": "The `@nx/expo:prebuild` executor is deprecated and will be removed in Nx v24. Run `nx g @nx/expo:convert-to-inferred` to migrate to the `@nx/expo/plugin` inferred plugin. See https://nx.dev/docs/guides/tasks--caching/convert-to-inferred for details.",
10
11
  "properties": {
11
12
  "clean": {
12
13
  "type": "boolean",
@@ -1 +1 @@
1
- {"version":3,"file":"run.impl.d.ts","sourceRoot":"","sources":["../../../../../../packages/expo/src/executors/run/run.impl.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,eAAe,EAAS,MAAM,YAAY,CAAC;AAOpD,OAAO,EAAE,cAAc,EAAE,MAAM,UAAU,CAAC;AAI1C,MAAM,WAAW,aAAa;IAC5B,OAAO,EAAE,OAAO,CAAC;CAClB;AAID,wBAA+B,WAAW,CACxC,OAAO,EAAE,cAAc,EACvB,OAAO,EAAE,eAAe,GACvB,cAAc,CAAC,aAAa,CAAC,CAkC/B"}
1
+ {"version":3,"file":"run.impl.d.ts","sourceRoot":"","sources":["../../../../../../packages/expo/src/executors/run/run.impl.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,eAAe,EAAS,MAAM,YAAY,CAAC;AAOpD,OAAO,EAAE,cAAc,EAAE,MAAM,UAAU,CAAC;AAK1C,MAAM,WAAW,aAAa;IAC5B,OAAO,EAAE,OAAO,CAAC;CAClB;AAID,wBAA+B,WAAW,CACxC,OAAO,EAAE,cAAc,EACvB,OAAO,EAAE,eAAe,GACvB,cAAc,CAAC,aAAa,CAAC,CAoC/B"}
@@ -9,8 +9,10 @@ const os_1 = require("os");
9
9
  const path_1 = require("path");
10
10
  const prebuild_impl_1 = require("../prebuild/prebuild.impl");
11
11
  const pod_install_task_1 = require("../../utils/pod-install-task");
12
+ const deprecation_1 = require("../../utils/deprecation");
12
13
  let childProcess;
13
14
  async function* runExecutor(options, context) {
15
+ (0, deprecation_1.warnExpoExecutorDeprecation)('run');
14
16
  if ((0, os_1.platform)() !== 'darwin' && options.platform === 'ios') {
15
17
  throw new Error(`The run-ios build requires Mac to run`);
16
18
  }
@@ -8,6 +8,7 @@
8
8
  "title": "Run iOS or Android application",
9
9
  "description": "Run Expo target options.",
10
10
  "type": "object",
11
+ "x-deprecated": "The `@nx/expo:run` executor is deprecated and will be removed in Nx v24. Run `nx g @nx/expo:convert-to-inferred` to migrate to the `@nx/expo/plugin` inferred plugin. See https://nx.dev/docs/guides/tasks--caching/convert-to-inferred for details.",
11
12
  "properties": {
12
13
  "platform": {
13
14
  "description": "Platform to run for (ios, android).",
@@ -8,6 +8,7 @@
8
8
  "title": "Serve web app for Expo",
9
9
  "description": "Packager Server target options.",
10
10
  "type": "object",
11
+ "x-deprecated": "The `@nx/expo:serve` executor is deprecated and will be removed in Nx v24. Run `nx g @nx/expo:convert-to-inferred` to migrate to the `@nx/expo/plugin` inferred plugin. See https://nx.dev/docs/guides/tasks--caching/convert-to-inferred for details.",
11
12
  "properties": {
12
13
  "port": {
13
14
  "type": "number",
@@ -1 +1 @@
1
- {"version":3,"file":"serve.impl.d.ts","sourceRoot":"","sources":["../../../../../../packages/expo/src/executors/serve/serve.impl.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,eAAe,EAAiB,MAAM,YAAY,CAAC;AAE5D,OAAO,EAAE,YAAY,EAAQ,MAAM,eAAe,CAAC;AAGnD,OAAO,EAAE,uBAAuB,EAAE,MAAM,UAAU,CAAC;AAEnD,MAAM,WAAW,eAAe;IAC9B,IAAI,CAAC,EAAE,MAAM,CAAC;IACd,OAAO,CAAC,EAAE,MAAM,CAAC;IACjB,OAAO,EAAE,OAAO,CAAC;CAClB;AAED,wBAA+B,aAAa,CAC1C,OAAO,EAAE,uBAAuB,EAChC,OAAO,EAAE,eAAe,GACvB,cAAc,CAAC,eAAe,CAAC,CA0BjC;AAED,wBAAsB,WAAW,CAC/B,aAAa,EAAE,MAAM,EACrB,WAAW,EAAE,MAAM,EACnB,OAAO,EAAE,uBAAuB,GAC/B,OAAO,CAAC,YAAY,CAAC,CAmBvB"}
1
+ {"version":3,"file":"serve.impl.d.ts","sourceRoot":"","sources":["../../../../../../packages/expo/src/executors/serve/serve.impl.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,eAAe,EAAiB,MAAM,YAAY,CAAC;AAE5D,OAAO,EAAE,YAAY,EAAQ,MAAM,eAAe,CAAC;AAGnD,OAAO,EAAE,uBAAuB,EAAE,MAAM,UAAU,CAAC;AAGnD,MAAM,WAAW,eAAe;IAC9B,IAAI,CAAC,EAAE,MAAM,CAAC;IACd,OAAO,CAAC,EAAE,MAAM,CAAC;IACjB,OAAO,EAAE,OAAO,CAAC;CAClB;AAED,wBAA+B,aAAa,CAC1C,OAAO,EAAE,uBAAuB,EAChC,OAAO,EAAE,eAAe,GACvB,cAAc,CAAC,eAAe,CAAC,CA4BjC;AAED,wBAAsB,WAAW,CAC/B,aAAa,EAAE,MAAM,EACrB,WAAW,EAAE,MAAM,EACnB,OAAO,EAAE,uBAAuB,GAC/B,OAAO,CAAC,YAAY,CAAC,CAmBvB"}
@@ -7,7 +7,9 @@ const internal_1 = require("@nx/devkit/internal");
7
7
  const child_process_1 = require("child_process");
8
8
  const path_1 = require("path");
9
9
  const is_packager_running_1 = require("./lib/is-packager-running");
10
+ const deprecation_1 = require("../../utils/deprecation");
10
11
  async function* serveExecutor(options, context) {
12
+ (0, deprecation_1.warnExpoExecutorDeprecation)('serve');
11
13
  const projectRoot = context.projectsConfigurations.projects[context.projectName].root;
12
14
  const serveProcess = await runCliServe(context.root, projectRoot, options);
13
15
  yield {
@@ -8,6 +8,7 @@
8
8
  "title": "Packager Server for Expo",
9
9
  "description": "Packager Server target options.",
10
10
  "type": "object",
11
+ "x-deprecated": "The `@nx/expo:start` executor is deprecated and will be removed in Nx v24. Run `nx g @nx/expo:convert-to-inferred` to migrate to the `@nx/expo/plugin` inferred plugin. See https://nx.dev/docs/guides/tasks--caching/convert-to-inferred for details.",
11
12
  "properties": {
12
13
  "forceManifestType": {
13
14
  "type": "string",
@@ -1 +1 @@
1
- {"version":3,"file":"start.impl.d.ts","sourceRoot":"","sources":["../../../../../../packages/expo/src/executors/start/start.impl.ts"],"names":[],"mappings":"AACA,OAAO,EAAE,eAAe,EAAiB,MAAM,YAAY,CAAC;AAK5D,OAAO,EAAE,gBAAgB,EAAE,MAAM,UAAU,CAAC;AAE5C,MAAM,WAAW,eAAe;IAC9B,OAAO,CAAC,EAAE,MAAM,CAAC;IACjB,OAAO,EAAE,OAAO,CAAC;CAClB;AAID,wBAA+B,aAAa,CAC1C,OAAO,EAAE,gBAAgB,EACzB,OAAO,EAAE,eAAe,GACvB,cAAc,CAAC,eAAe,CAAC,CAmBjC"}
1
+ {"version":3,"file":"start.impl.d.ts","sourceRoot":"","sources":["../../../../../../packages/expo/src/executors/start/start.impl.ts"],"names":[],"mappings":"AACA,OAAO,EAAE,eAAe,EAAiB,MAAM,YAAY,CAAC;AAK5D,OAAO,EAAE,gBAAgB,EAAE,MAAM,UAAU,CAAC;AAG5C,MAAM,WAAW,eAAe;IAC9B,OAAO,CAAC,EAAE,MAAM,CAAC;IACjB,OAAO,EAAE,OAAO,CAAC;CAClB;AAID,wBAA+B,aAAa,CAC1C,OAAO,EAAE,gBAAgB,EACzB,OAAO,EAAE,eAAe,GACvB,cAAc,CAAC,eAAe,CAAC,CAqBjC"}
@@ -7,8 +7,10 @@ const devkit_1 = require("@nx/devkit");
7
7
  const internal_1 = require("@nx/devkit/internal");
8
8
  const child_process_1 = require("child_process");
9
9
  const path_1 = require("path");
10
+ const deprecation_1 = require("../../utils/deprecation");
10
11
  let childProcess;
11
12
  async function* startExecutor(options, context) {
13
+ (0, deprecation_1.warnExpoExecutorDeprecation)('start');
12
14
  const projectRoot = context.projectsConfigurations.projects[context.projectName].root;
13
15
  try {
14
16
  const baseUrl = `http://localhost:${options.port}`;
@@ -4,6 +4,7 @@
4
4
  "title": "EXPO EAS Submit Executor",
5
5
  "description": "Submit app binary to App Store and/or Play Store.",
6
6
  "type": "object",
7
+ "x-deprecated": "The `@nx/expo:submit` executor is deprecated and will be removed in Nx v24. Run `nx g @nx/expo:convert-to-inferred` to migrate to the `@nx/expo/plugin` inferred plugin. See https://nx.dev/docs/guides/tasks--caching/convert-to-inferred for details.",
7
8
  "presets": [
8
9
  {
9
10
  "name": "Submit for a specific platform",
@@ -1 +1 @@
1
- {"version":3,"file":"submit.impl.d.ts","sourceRoot":"","sources":["../../../../../../packages/expo/src/executors/submit/submit.impl.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,eAAe,EAAS,MAAM,YAAY,CAAC;AAOpD,OAAO,EAAE,oBAAoB,EAAE,MAAM,UAAU,CAAC;AAEhD,MAAM,WAAW,uBAAuB;IACtC,OAAO,EAAE,OAAO,CAAC;CAClB;AAID,wBAA+B,cAAc,CAC3C,OAAO,EAAE,oBAAoB,EAC7B,OAAO,EAAE,eAAe,GACvB,cAAc,CAAC,uBAAuB,CAAC,CAazC"}
1
+ {"version":3,"file":"submit.impl.d.ts","sourceRoot":"","sources":["../../../../../../packages/expo/src/executors/submit/submit.impl.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,eAAe,EAAS,MAAM,YAAY,CAAC;AAOpD,OAAO,EAAE,oBAAoB,EAAE,MAAM,UAAU,CAAC;AAGhD,MAAM,WAAW,uBAAuB;IACtC,OAAO,EAAE,OAAO,CAAC;CAClB;AAID,wBAA+B,cAAc,CAC3C,OAAO,EAAE,oBAAoB,EAC7B,OAAO,EAAE,eAAe,GACvB,cAAc,CAAC,uBAAuB,CAAC,CAezC"}
@@ -6,8 +6,10 @@ const internal_1 = require("@nx/devkit/internal");
6
6
  const path_1 = require("path");
7
7
  const child_process_1 = require("child_process");
8
8
  const resolve_eas_1 = require("../../utils/resolve-eas");
9
+ const deprecation_1 = require("../../utils/deprecation");
9
10
  let childProcess;
10
11
  async function* submitExecutor(options, context) {
12
+ (0, deprecation_1.warnExpoExecutorDeprecation)('submit');
11
13
  const projectRoot = context.projectsConfigurations.projects[context.projectName].root;
12
14
  try {
13
15
  await runCliSubmit(context.root, projectRoot, options);
@@ -1 +1 @@
1
- {"version":3,"file":"application.d.ts","sourceRoot":"","sources":["../../../../../../packages/expo/src/generators/application/application.ts"],"names":[],"mappings":"AAAA,OAAO,EAEL,iBAAiB,EAGjB,IAAI,EACL,MAAM,YAAY,CAAC;AAiBpB,OAAO,EAAE,MAAM,EAAE,MAAM,UAAU,CAAC;AAMlC,wBAAsB,wBAAwB,CAC5C,IAAI,EAAE,IAAI,EACV,MAAM,EAAE,MAAM,GACb,OAAO,CAAC,iBAAiB,CAAC,CAM5B;AAED,wBAAsB,gCAAgC,CACpD,IAAI,EAAE,IAAI,EACV,MAAM,EAAE,MAAM,GACb,OAAO,CAAC,iBAAiB,CAAC,CAmF5B;AAED,eAAe,wBAAwB,CAAC"}
1
+ {"version":3,"file":"application.d.ts","sourceRoot":"","sources":["../../../../../../packages/expo/src/generators/application/application.ts"],"names":[],"mappings":"AACA,OAAO,EAEL,iBAAiB,EAGjB,IAAI,EACL,MAAM,YAAY,CAAC;AAiBpB,OAAO,EAAE,MAAM,EAAE,MAAM,UAAU,CAAC;AAGlC,wBAAsB,wBAAwB,CAC5C,IAAI,EAAE,IAAI,EACV,MAAM,EAAE,MAAM,GACb,OAAO,CAAC,iBAAiB,CAAC,CAM5B;AAED,wBAAsB,gCAAgC,CACpD,IAAI,EAAE,IAAI,EACV,MAAM,EAAE,MAAM,GACb,OAAO,CAAC,iBAAiB,CAAC,CAmF5B;AAED,eAAe,wBAAwB,CAAC"}
@@ -3,9 +3,10 @@ Object.defineProperty(exports, "__esModule", { value: true });
3
3
  exports.expoApplicationGenerator = expoApplicationGenerator;
4
4
  exports.expoApplicationGeneratorInternal = expoApplicationGeneratorInternal;
5
5
  const tslib_1 = require("tslib");
6
+ const internal_1 = require("@nx/devkit/internal");
6
7
  const devkit_1 = require("@nx/devkit");
7
8
  const js_1 = require("@nx/js");
8
- const ts_solution_setup_1 = require("@nx/js/src/utils/typescript/ts-solution-setup");
9
+ const internal_2 = require("@nx/js/internal");
9
10
  const add_linting_1 = require("../../utils/add-linting");
10
11
  const add_jest_1 = require("../../utils/jest/add-jest");
11
12
  const normalize_options_1 = require("./lib/normalize-options");
@@ -16,8 +17,6 @@ const add_eas_scripts_1 = require("./lib/add-eas-scripts");
16
17
  const add_e2e_1 = require("./lib/add-e2e");
17
18
  const ensure_dependencies_1 = require("../../utils/ensure-dependencies");
18
19
  const init_root_babel_config_1 = require("../../utils/init-root-babel-config");
19
- const log_show_project_command_1 = require("@nx/devkit/src/utils/log-show-project-command");
20
- const sort_fields_1 = require("@nx/js/src/utils/package-json/sort-fields");
21
20
  async function expoApplicationGenerator(host, schema) {
22
21
  return await expoApplicationGeneratorInternal(host, {
23
22
  addPlugin: false,
@@ -27,7 +26,7 @@ async function expoApplicationGenerator(host, schema) {
27
26
  }
28
27
  async function expoApplicationGeneratorInternal(host, schema) {
29
28
  const tasks = [];
30
- const addTsPlugin = (0, ts_solution_setup_1.shouldConfigureTsSolutionSetup)(host, schema.addPlugin, schema.useTsSolution);
29
+ const addTsPlugin = (0, internal_2.shouldConfigureTsSolutionSetup)(host, schema.addPlugin, schema.useTsSolution);
31
30
  const jsInitTask = await (0, js_1.initGenerator)(host, {
32
31
  ...schema,
33
32
  skipFormat: true,
@@ -48,7 +47,7 @@ async function expoApplicationGeneratorInternal(host, schema) {
48
47
  // If we are using the new TS solution
49
48
  // We need to update the workspace file (package.json or pnpm-workspaces.yaml) to include the new project
50
49
  if (options.isTsSolutionSetup) {
51
- await (0, ts_solution_setup_1.addProjectToTsSolutionWorkspace)(host, options.appProjectRoot);
50
+ await (0, internal_2.addProjectToTsSolutionWorkspace)(host, options.appProjectRoot);
52
51
  }
53
52
  const lintTask = await (0, add_linting_1.addLinting)(host, {
54
53
  ...options,
@@ -63,7 +62,7 @@ async function expoApplicationGeneratorInternal(host, schema) {
63
62
  const e2eTask = await (0, add_e2e_1.addE2e)(host, options);
64
63
  tasks.push(e2eTask);
65
64
  (0, add_eas_scripts_1.addEasScripts)(host);
66
- (0, ts_solution_setup_1.updateTsconfigFiles)(host, options.appProjectRoot, 'tsconfig.app.json', {
65
+ (0, internal_2.updateTsconfigFiles)(host, options.appProjectRoot, 'tsconfig.app.json', {
67
66
  jsx: 'react-jsx',
68
67
  module: 'esnext',
69
68
  moduleResolution: 'bundler',
@@ -71,12 +70,12 @@ async function expoApplicationGeneratorInternal(host, schema) {
71
70
  }, options.linter === 'eslint'
72
71
  ? ['eslint.config.js', 'eslint.config.cjs', 'eslint.config.mjs']
73
72
  : undefined);
74
- (0, sort_fields_1.sortPackageJsonFields)(host, options.appProjectRoot);
73
+ (0, internal_2.sortPackageJsonFields)(host, options.appProjectRoot);
75
74
  if (!options.skipFormat) {
76
75
  await (0, devkit_1.formatFiles)(host);
77
76
  }
78
77
  tasks.push(() => {
79
- (0, log_show_project_command_1.logShowProjectCommand)(options.projectName);
78
+ (0, internal_1.logShowProjectCommand)(options.projectName);
80
79
  });
81
80
  return (0, devkit_1.runTasksInSerial)(...tasks);
82
81
  }
@@ -1 +1 @@
1
- {"version":3,"file":"add-e2e.d.ts","sourceRoot":"","sources":["../../../../../../../packages/expo/src/generators/application/lib/add-e2e.ts"],"names":[],"mappings":"AAAA,OAAO,EAGL,iBAAiB,EAGjB,IAAI,EAEL,MAAM,YAAY,CAAC;AAKpB,OAAO,EAAE,gBAAgB,EAAE,MAAM,qBAAqB,CAAC;AAEvD,wBAAsB,MAAM,CAC1B,IAAI,EAAE,IAAI,EACV,OAAO,EAAE,gBAAgB,GACxB,OAAO,CAAC,iBAAiB,CAAC,CAiJ5B"}
1
+ {"version":3,"file":"add-e2e.d.ts","sourceRoot":"","sources":["../../../../../../../packages/expo/src/generators/application/lib/add-e2e.ts"],"names":[],"mappings":"AAIA,OAAO,EAGL,iBAAiB,EAGjB,IAAI,EAEL,MAAM,YAAY,CAAC;AAIpB,OAAO,EAAE,gBAAgB,EAAE,MAAM,qBAAqB,CAAC;AAEvD,wBAAsB,MAAM,CAC1B,IAAI,EAAE,IAAI,EACV,OAAO,EAAE,gBAAgB,GACxB,OAAO,CAAC,iBAAiB,CAAC,CAiJ5B"}
@@ -1,8 +1,8 @@
1
1
  "use strict";
2
2
  Object.defineProperty(exports, "__esModule", { value: true });
3
3
  exports.addE2e = addE2e;
4
+ const internal_1 = require("@nx/devkit/internal");
4
5
  const devkit_1 = require("@nx/devkit");
5
- const e2e_web_server_info_utils_1 = require("@nx/devkit/src/generators/e2e-web-server-info-utils");
6
6
  const has_expo_plugin_1 = require("../../../utils/has-expo-plugin");
7
7
  const versions_1 = require("../../../utils/versions");
8
8
  async function addE2e(tree, options) {
@@ -122,11 +122,11 @@ async function addE2e(tree, options) {
122
122
  async function getExpoE2EWebServerInfo(tree, projectName, configFilePath, isPluginBeingAdded) {
123
123
  const nxJson = (0, devkit_1.readNxJson)(tree);
124
124
  let e2ePort = isPluginBeingAdded ? 8081 : 4200;
125
- if (nxJson.targetDefaults?.['serve'] &&
126
- nxJson.targetDefaults?.['serve'].options?.port) {
127
- e2ePort = nxJson.targetDefaults?.['serve'].options?.port;
125
+ const serveTargetOptions = (0, internal_1.readTargetDefaultsForTarget)('serve', nxJson.targetDefaults)?.options;
126
+ if (serveTargetOptions?.port) {
127
+ e2ePort = serveTargetOptions.port;
128
128
  }
129
- return (0, e2e_web_server_info_utils_1.getE2EWebServerInfo)(tree, projectName, {
129
+ return (0, internal_1.getE2EWebServerInfo)(tree, projectName, {
130
130
  plugin: '@nx/expo/plugin',
131
131
  serveTargetName: 'serveTargetName',
132
132
  serveStaticTargetName: 'serveTargetName',
@@ -1 +1 @@
1
- {"version":3,"file":"add-project.d.ts","sourceRoot":"","sources":["../../../../../../../packages/expo/src/generators/application/lib/add-project.ts"],"names":[],"mappings":"AAAA,OAAO,EAML,IAAI,EAEL,MAAM,YAAY,CAAC;AAIpB,OAAO,EAAE,gBAAgB,EAAE,MAAM,qBAAqB,CAAC;AAEvD,wBAAgB,UAAU,CAAC,IAAI,EAAE,IAAI,EAAE,OAAO,EAAE,gBAAgB,QAuD/D"}
1
+ {"version":3,"file":"add-project.d.ts","sourceRoot":"","sources":["../../../../../../../packages/expo/src/generators/application/lib/add-project.ts"],"names":[],"mappings":"AACA,OAAO,EAML,IAAI,EAEL,MAAM,YAAY,CAAC;AAIpB,OAAO,EAAE,gBAAgB,EAAE,MAAM,qBAAqB,CAAC;AAEvD,wBAAgB,UAAU,CAAC,IAAI,EAAE,IAAI,EAAE,OAAO,EAAE,gBAAgB,QAwD/D"}
@@ -1,13 +1,15 @@
1
1
  "use strict";
2
2
  Object.defineProperty(exports, "__esModule", { value: true });
3
3
  exports.addProject = addProject;
4
+ const internal_1 = require("@nx/devkit/internal");
4
5
  const devkit_1 = require("@nx/devkit");
5
- const target_defaults_utils_1 = require("@nx/devkit/src/generators/target-defaults-utils");
6
6
  const has_expo_plugin_1 = require("../../../utils/has-expo-plugin");
7
+ const deprecation_1 = require("../../../utils/deprecation");
7
8
  function addProject(host, options) {
8
9
  const hasPlugin = (0, has_expo_plugin_1.hasExpoPlugin)(host);
9
10
  if (!hasPlugin) {
10
- (0, target_defaults_utils_1.addBuildTargetDefaults)(host, '@nx/expo:build');
11
+ (0, deprecation_1.warnExpoExecutorGenerating)();
12
+ (0, internal_1.addBuildTargetDefaults)(host, '@nx/expo:build');
11
13
  }
12
14
  const projectConfiguration = {
13
15
  root: options.appProjectRoot,
@@ -2,11 +2,11 @@
2
2
  Object.defineProperty(exports, "__esModule", { value: true });
3
3
  exports.normalizeOptions = normalizeOptions;
4
4
  const devkit_1 = require("@nx/devkit");
5
- const project_name_and_root_utils_1 = require("@nx/devkit/src/generators/project-name-and-root-utils");
6
- const ts_solution_setup_1 = require("@nx/js/src/utils/typescript/ts-solution-setup");
5
+ const internal_1 = require("@nx/devkit/internal");
6
+ const internal_2 = require("@nx/js/internal");
7
7
  async function normalizeOptions(host, options) {
8
- await (0, project_name_and_root_utils_1.ensureRootProjectName)(options, 'application');
9
- const { projectName, names: projectNames, projectRoot: appProjectRoot, importPath, } = await (0, project_name_and_root_utils_1.determineProjectNameAndRootOptions)(host, {
8
+ await (0, internal_1.ensureRootProjectName)(options, 'application');
9
+ const { projectName, names: projectNames, projectRoot: appProjectRoot, importPath, } = await (0, internal_1.determineProjectNameAndRootOptions)(host, {
10
10
  name: options.name,
11
11
  projectType: 'application',
12
12
  directory: options.directory,
@@ -20,7 +20,7 @@ async function normalizeOptions(host, options) {
20
20
  ? options.tags.split(',').map((s) => s.trim())
21
21
  : [];
22
22
  const rootProject = appProjectRoot === '.';
23
- const isTsSolutionSetup = (0, ts_solution_setup_1.isUsingTsSolutionSetup)(host);
23
+ const isTsSolutionSetup = (0, internal_2.isUsingTsSolutionSetup)(host);
24
24
  const appProjectName = !isTsSolutionSetup || options.name ? projectName : importPath;
25
25
  const useProjectJson = options.useProjectJson ?? !isTsSolutionSetup;
26
26
  const e2eProjectName = rootProject ? 'e2e' : `${appProjectName}-e2e`;
@@ -7,7 +7,7 @@ const devkit_1 = require("@nx/devkit");
7
7
  const normalize_options_1 = require("./lib/normalize-options");
8
8
  const add_import_1 = require("./lib/add-import");
9
9
  const path_1 = require("path");
10
- const ts_solution_setup_1 = require("@nx/js/src/utils/typescript/ts-solution-setup");
10
+ const internal_1 = require("@nx/js/internal");
11
11
  async function expoComponentGenerator(host, schema) {
12
12
  const options = await (0, normalize_options_1.normalizeOptions)(host, schema);
13
13
  createComponentFiles(host, options);
@@ -28,7 +28,7 @@ function createComponentFiles(host, options) {
28
28
  function addExportsToBarrel(host, options) {
29
29
  const workspace = (0, devkit_1.getProjects)(host);
30
30
  const proj = workspace.get(options.projectName);
31
- const isApp = (0, ts_solution_setup_1.getProjectType)(host, proj.root, proj.projectType) === 'application';
31
+ const isApp = (0, internal_1.getProjectType)(host, proj.root, proj.projectType) === 'application';
32
32
  if (options.export && !isApp) {
33
33
  const indexFilePath = (0, devkit_1.joinPathFragments)(...(options.projectSourceRoot
34
34
  ? [options.projectSourceRoot]