@nx/react 16.4.0-beta.7 → 16.4.0-beta.8
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/migrations.json +17 -0
- package/package.json +7 -7
- package/src/generators/cypress-component-configuration/lib/add-files.d.ts +1 -1
- package/src/generators/cypress-component-configuration/lib/add-files.js +4 -1
- package/src/utils/ct-utils.d.ts +2 -5
- package/src/utils/ct-utils.js +11 -7
- package/src/utils/versions.d.ts +3 -3
- package/src/utils/versions.js +3 -3
package/migrations.json
CHANGED
|
@@ -916,6 +916,23 @@
|
|
|
916
916
|
"alwaysAddToPackageJson": false
|
|
917
917
|
}
|
|
918
918
|
}
|
|
919
|
+
},
|
|
920
|
+
"16.4.0-beta.8": {
|
|
921
|
+
"version": "16.4.0-beta.8",
|
|
922
|
+
"packages": {
|
|
923
|
+
"@emotion/styled": {
|
|
924
|
+
"version": "11.11.0",
|
|
925
|
+
"alwaysAddToPackageJson": false
|
|
926
|
+
},
|
|
927
|
+
"@emotion/react": {
|
|
928
|
+
"version": "11.11.1",
|
|
929
|
+
"alwaysAddToPackageJson": false
|
|
930
|
+
},
|
|
931
|
+
"@emotion/babel-plugin": {
|
|
932
|
+
"version": "11.11.0",
|
|
933
|
+
"alwaysAddToPackageJson": false
|
|
934
|
+
}
|
|
935
|
+
}
|
|
919
936
|
}
|
|
920
937
|
}
|
|
921
938
|
}
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@nx/react",
|
|
3
|
-
"version": "16.4.0-beta.
|
|
3
|
+
"version": "16.4.0-beta.8",
|
|
4
4
|
"private": false,
|
|
5
5
|
"description": "The React plugin for Nx contains executors and generators for managing React applications and libraries within an Nx workspace. It provides:\n\n\n- Integration with libraries such as Jest, Cypress, and Storybook.\n\n- Generators for applications, libraries, components, hooks, and more.\n\n- Library build support for publishing packages to npm or other registries.\n\n- Utilities for automatic workspace refactoring.",
|
|
6
6
|
"repository": {
|
|
@@ -31,11 +31,11 @@
|
|
|
31
31
|
"migrations": "./migrations.json"
|
|
32
32
|
},
|
|
33
33
|
"dependencies": {
|
|
34
|
-
"@nrwl/react": "16.4.0-beta.
|
|
35
|
-
"@nx/devkit": "16.4.0-beta.
|
|
36
|
-
"@nx/js": "16.4.0-beta.
|
|
37
|
-
"@nx/linter": "16.4.0-beta.
|
|
38
|
-
"@nx/web": "16.4.0-beta.
|
|
34
|
+
"@nrwl/react": "16.4.0-beta.8",
|
|
35
|
+
"@nx/devkit": "16.4.0-beta.8",
|
|
36
|
+
"@nx/js": "16.4.0-beta.8",
|
|
37
|
+
"@nx/linter": "16.4.0-beta.8",
|
|
38
|
+
"@nx/web": "16.4.0-beta.8",
|
|
39
39
|
"@phenomnomnominal/tsquery": "~5.0.1",
|
|
40
40
|
"@svgr/webpack": "^8.0.1",
|
|
41
41
|
"chalk": "^4.1.0",
|
|
@@ -46,5 +46,5 @@
|
|
|
46
46
|
"access": "public"
|
|
47
47
|
},
|
|
48
48
|
"types": "./index.d.ts",
|
|
49
|
-
"gitHead": "
|
|
49
|
+
"gitHead": "a6589ab111fc01fd4d2cd215c31bfcff004dfc00"
|
|
50
50
|
}
|
|
@@ -1,4 +1,4 @@
|
|
|
1
1
|
import { ProjectConfiguration, Tree } from '@nx/devkit';
|
|
2
2
|
import type { CypressComponentConfigurationSchema } from '../schema';
|
|
3
|
-
import { FoundTarget } from '
|
|
3
|
+
import { FoundTarget } from '@nx/cypress/src/utils/find-target-options';
|
|
4
4
|
export declare function addFiles(tree: Tree, projectConfig: ProjectConfiguration, options: CypressComponentConfigurationSchema, found: FoundTarget): Promise<void>;
|
|
@@ -12,7 +12,10 @@ function addFiles(tree, projectConfig, options, found) {
|
|
|
12
12
|
// must dyanmicaly import to prevent packages not using cypress from erroring out
|
|
13
13
|
// when importing react
|
|
14
14
|
const { addMountDefinition, addDefaultCTConfig } = yield Promise.resolve().then(() => require('@nx/cypress/src/utils/config'));
|
|
15
|
-
|
|
15
|
+
// Specifically undefined to allow Remix workaround of passing an empty string
|
|
16
|
+
const actualBundler = options.buildTarget !== undefined && options.bundler
|
|
17
|
+
? options.bundler
|
|
18
|
+
: yield (0, ct_utils_1.getBundlerFromTarget)(found, tree);
|
|
16
19
|
if (options.bundler && options.bundler !== actualBundler) {
|
|
17
20
|
devkit_1.logger.warn(`You have specified ${options.bundler} as the bundler but this project is configured to use ${actualBundler}.
|
|
18
21
|
This may cause errors. If you are seeing errors, try removing the --bundler option.`);
|
package/src/utils/ct-utils.d.ts
CHANGED
|
@@ -1,8 +1,5 @@
|
|
|
1
|
-
import {
|
|
2
|
-
|
|
3
|
-
config?: TargetConfiguration;
|
|
4
|
-
target: string;
|
|
5
|
-
}
|
|
1
|
+
import { Tree } from '@nx/devkit';
|
|
2
|
+
import { type FoundTarget } from '@nx/cypress/src/utils/find-target-options';
|
|
6
3
|
export declare function addCTTargetWithBuildTarget(tree: Tree, options: {
|
|
7
4
|
project: string;
|
|
8
5
|
buildTarget: string;
|
package/src/utils/ct-utils.js
CHANGED
|
@@ -10,13 +10,17 @@ const allowedFileExt = new RegExp(/\.[jt]sx?/);
|
|
|
10
10
|
const isSpecFile = new RegExp(/(spec|test)\./);
|
|
11
11
|
function addCTTargetWithBuildTarget(tree, options) {
|
|
12
12
|
return tslib_1.__awaiter(this, void 0, void 0, function* () {
|
|
13
|
-
|
|
14
|
-
|
|
15
|
-
|
|
16
|
-
|
|
17
|
-
|
|
18
|
-
|
|
19
|
-
|
|
13
|
+
let found = { target: options.buildTarget, config: undefined };
|
|
14
|
+
// Specifically undefined as a workaround for Remix to pass an empty string as the buildTarget
|
|
15
|
+
if (options.buildTarget === undefined) {
|
|
16
|
+
const { findBuildConfig } = yield Promise.resolve().then(() => require('@nx/cypress/src/utils/find-target-options'));
|
|
17
|
+
found = yield findBuildConfig(tree, {
|
|
18
|
+
project: options.project,
|
|
19
|
+
buildTarget: options.buildTarget,
|
|
20
|
+
validExecutorNames: options.validExecutorNames,
|
|
21
|
+
});
|
|
22
|
+
assertValidConfig(found === null || found === void 0 ? void 0 : found.config);
|
|
23
|
+
}
|
|
20
24
|
const projectConfig = (0, devkit_1.readProjectConfiguration)(tree, options.project);
|
|
21
25
|
projectConfig.targets['component-test'].options = Object.assign(Object.assign({}, projectConfig.targets['component-test'].options), { devServerTarget: found.target, skipServe: true });
|
|
22
26
|
(0, devkit_1.updateProjectConfiguration)(tree, options.project, projectConfig);
|
package/src/utils/versions.d.ts
CHANGED
|
@@ -12,9 +12,9 @@ export declare const typesNodeVersion = "18.14.2";
|
|
|
12
12
|
export declare const babelPresetReactVersion = "^7.14.5";
|
|
13
13
|
export declare const styledComponentsVersion = "5.3.6";
|
|
14
14
|
export declare const typesStyledComponentsVersion = "5.1.26";
|
|
15
|
-
export declare const emotionStyledVersion = "11.
|
|
16
|
-
export declare const emotionReactVersion = "11.
|
|
17
|
-
export declare const emotionBabelPlugin = "11.
|
|
15
|
+
export declare const emotionStyledVersion = "11.11.0";
|
|
16
|
+
export declare const emotionReactVersion = "11.11.1";
|
|
17
|
+
export declare const emotionBabelPlugin = "11.11.0";
|
|
18
18
|
export declare const styledJsxVersion = "5.1.2";
|
|
19
19
|
export declare const reactRouterDomVersion = "6.11.2";
|
|
20
20
|
export declare const testingLibraryReactVersion = "14.0.0";
|
package/src/utils/versions.js
CHANGED
|
@@ -16,9 +16,9 @@ exports.typesNodeVersion = '18.14.2';
|
|
|
16
16
|
exports.babelPresetReactVersion = '^7.14.5';
|
|
17
17
|
exports.styledComponentsVersion = '5.3.6';
|
|
18
18
|
exports.typesStyledComponentsVersion = '5.1.26';
|
|
19
|
-
exports.emotionStyledVersion = '11.
|
|
20
|
-
exports.emotionReactVersion = '11.
|
|
21
|
-
exports.emotionBabelPlugin = '11.
|
|
19
|
+
exports.emotionStyledVersion = '11.11.0';
|
|
20
|
+
exports.emotionReactVersion = '11.11.1';
|
|
21
|
+
exports.emotionBabelPlugin = '11.11.0';
|
|
22
22
|
// WARNING: This needs to be in sync with Next.js' dependency or else there might be issues.
|
|
23
23
|
exports.styledJsxVersion = '5.1.2';
|
|
24
24
|
exports.reactRouterDomVersion = '6.11.2';
|