@nx/detox 20.3.0 → 20.4.0-beta.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/LICENSE CHANGED
@@ -1,6 +1,6 @@
1
1
  (The MIT License)
2
2
 
3
- Copyright (c) 2017-2024 Narwhal Technologies Inc.
3
+ Copyright (c) 2017-2025 Narwhal Technologies Inc.
4
4
 
5
5
  Permission is hereby granted, free of charge, to any person obtaining
6
6
  a copy of this software and associated documentation files (the
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@nx/detox",
3
- "version": "20.3.0",
3
+ "version": "20.4.0-beta.0",
4
4
  "private": false,
5
5
  "description": "The Nx Plugin for Detox contains executors and generators for allowing your workspace to use the powerful Detox integration testing capabilities.",
6
6
  "keywords": [
@@ -27,11 +27,11 @@
27
27
  "main": "./index",
28
28
  "types": "index.d.ts",
29
29
  "dependencies": {
30
- "@nx/devkit": "20.3.0",
31
- "@nx/jest": "20.3.0",
32
- "@nx/js": "20.3.0",
33
- "@nx/eslint": "20.3.0",
34
- "@nx/react": "20.3.0",
30
+ "@nx/devkit": "20.4.0-beta.0",
31
+ "@nx/jest": "20.4.0-beta.0",
32
+ "@nx/js": "20.4.0-beta.0",
33
+ "@nx/eslint": "20.4.0-beta.0",
34
+ "@nx/react": "20.4.0-beta.0",
35
35
  "tslib": "^2.3.0"
36
36
  },
37
37
  "peerDependencies": {
@@ -25,6 +25,16 @@ async function detoxInitGeneratorInternal(host, schema) {
25
25
  buildTargetName: ['build', 'detox:build', 'detox-build'],
26
26
  startTargetName: ['start', 'detox:start', 'detox-start'],
27
27
  testTargetName: ['test', 'detox:test', 'detox-test'],
28
+ buildDepsTargetName: [
29
+ 'build-deps',
30
+ 'detox:build-deps',
31
+ 'detox-build-deps',
32
+ ],
33
+ watchDepsTargetName: [
34
+ 'watch-deps',
35
+ 'detox:watch-deps',
36
+ 'detox-watch-deps',
37
+ ],
28
38
  }, schema.updatePackageScripts);
29
39
  }
30
40
  if (!schema.skipFormat) {
@@ -3,6 +3,8 @@ export interface DetoxPluginOptions {
3
3
  buildTargetName?: string;
4
4
  startTargetName?: string;
5
5
  testTargetName?: string;
6
+ buildDepsTargetName?: string;
7
+ watchDepsTargetName?: string;
6
8
  }
7
9
  export declare const createNodesV2: CreateNodesV2<DetoxPluginOptions>;
8
10
  export declare const createNodes: CreateNodes<DetoxPluginOptions>;
@@ -9,6 +9,8 @@ const fs_1 = require("fs");
9
9
  const calculate_hash_for_create_nodes_1 = require("@nx/devkit/src/utils/calculate-hash-for-create-nodes");
10
10
  const cache_directory_1 = require("nx/src/utils/cache-directory");
11
11
  const devkit_internals_1 = require("nx/src/devkit-internals");
12
+ const util_1 = require("@nx/js/src/plugins/typescript/util");
13
+ const pmc = (0, devkit_1.getPackageManagerCommand)();
12
14
  function readTargetsCache(cachePath) {
13
15
  return (0, fs_1.existsSync)(cachePath) ? (0, devkit_1.readJsonFile)(cachePath) : {};
14
16
  }
@@ -77,6 +79,7 @@ function buildDetoxTargets(projectRoot, options, context) {
77
79
  inputs: getInputs(namedInputs),
78
80
  },
79
81
  };
82
+ (0, util_1.addBuildAndWatchDepsTargets)(context.workspaceRoot, projectRoot, targets, options, pmc);
80
83
  return targets;
81
84
  }
82
85
  function getInputs(namedInputs) {