@o3r/store-sync 12.2.5 → 12.2.7
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/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@o3r/store-sync",
|
|
3
|
-
"version": "12.2.
|
|
3
|
+
"version": "12.2.7",
|
|
4
4
|
"publishConfig": {
|
|
5
5
|
"access": "public"
|
|
6
6
|
},
|
|
@@ -13,18 +13,19 @@
|
|
|
13
13
|
"otter-module"
|
|
14
14
|
],
|
|
15
15
|
"peerDependencies": {
|
|
16
|
-
"@ama-sdk/core": "^12.2.
|
|
16
|
+
"@ama-sdk/core": "^12.2.7",
|
|
17
17
|
"@angular-devkit/core": "^19.0.0",
|
|
18
18
|
"@angular-devkit/schematics": "^19.0.0",
|
|
19
19
|
"@ngrx/entity": "^19.0.0",
|
|
20
20
|
"@ngrx/store": "^19.0.0",
|
|
21
|
-
"@o3r/core": "^12.2.
|
|
22
|
-
"@o3r/logger": "^12.2.
|
|
23
|
-
"@o3r/schematics": "^12.2.
|
|
21
|
+
"@o3r/core": "^12.2.7",
|
|
22
|
+
"@o3r/logger": "^12.2.7",
|
|
23
|
+
"@o3r/schematics": "^12.2.7",
|
|
24
24
|
"@schematics/angular": "^19.0.0",
|
|
25
25
|
"fast-deep-equal": "^3.1.3",
|
|
26
26
|
"rxjs": "^7.8.1",
|
|
27
|
-
"ts-node": "~10.9.2"
|
|
27
|
+
"ts-node": "~10.9.2",
|
|
28
|
+
"type-fest": "^4.30.1"
|
|
28
29
|
},
|
|
29
30
|
"peerDependenciesMeta": {
|
|
30
31
|
"@angular-devkit/core": {
|
|
@@ -38,6 +39,9 @@
|
|
|
38
39
|
},
|
|
39
40
|
"@schematics/angular": {
|
|
40
41
|
"optional": true
|
|
42
|
+
},
|
|
43
|
+
"type-fest": {
|
|
44
|
+
"optional": true
|
|
41
45
|
}
|
|
42
46
|
},
|
|
43
47
|
"dependencies": {
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../schematics/ng-add/index.ts"],"names":[],"mappings":"AACA,OAAO,EAGL,IAAI,EACL,MAAM,4BAA4B,CAAC;AAIpC,OAAO,KAAK,EACV,qBAAqB,EACtB,MAAM,UAAU,CAAC;
|
|
1
|
+
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../schematics/ng-add/index.ts"],"names":[],"mappings":"AACA,OAAO,EAGL,IAAI,EACL,MAAM,4BAA4B,CAAC;AAIpC,OAAO,KAAK,EACV,qBAAqB,EACtB,MAAM,UAAU,CAAC;AAqFlB;;;GAGG;AACH,eAAO,MAAM,KAAK,GAAI,SAAS,qBAAqB,KAAG,IAKtD,CAAC"}
|
|
@@ -3,10 +3,19 @@ Object.defineProperty(exports, "__esModule", { value: true });
|
|
|
3
3
|
exports.ngAdd = void 0;
|
|
4
4
|
const path = require("node:path");
|
|
5
5
|
const schematics_1 = require("@angular-devkit/schematics");
|
|
6
|
-
|
|
7
|
-
|
|
8
|
-
|
|
6
|
+
/**
|
|
7
|
+
* List of external dependencies to be added to the project as peer dependencies
|
|
8
|
+
*/
|
|
9
|
+
const dependenciesToInstall = [
|
|
10
|
+
'@ngrx/entity',
|
|
11
|
+
'@ngrx/store',
|
|
12
|
+
'fast-deep-equal',
|
|
13
|
+
'rxjs'
|
|
9
14
|
];
|
|
15
|
+
/**
|
|
16
|
+
* List of external dependencies to be added to the project as dev dependencies
|
|
17
|
+
*/
|
|
18
|
+
const devDependenciesToInstall = [];
|
|
10
19
|
const reportMissingSchematicsDep = (logger) => (reason) => {
|
|
11
20
|
logger.error(`[ERROR]: Adding store-sync has failed.
|
|
12
21
|
If the error is related to missing @o3r dependencies you need to install '@o3r/core' to be able to use the store-sync package. Please run 'ng add @o3r/core' .
|
|
@@ -20,9 +29,11 @@ Otherwise, use the error message as guidance.`);
|
|
|
20
29
|
function ngAddFn(options) {
|
|
21
30
|
return async (tree, context) => {
|
|
22
31
|
// use dynamic import to properly raise an exception if it is not an Otter project.
|
|
23
|
-
const { getPackageInstallConfig, applyEsLintFix, setupDependencies, getO3rPeerDeps, getProjectNewDependenciesTypes, getWorkspaceConfig,
|
|
32
|
+
const { getPackageInstallConfig, applyEsLintFix, setupDependencies, getO3rPeerDeps, getProjectNewDependenciesTypes, getWorkspaceConfig, getExternalDependenciesInfo } = await Promise.resolve().then(() => require('@o3r/schematics'));
|
|
24
33
|
const workspaceProject = options.projectName ? getWorkspaceConfig(tree)?.projects[options.projectName] : undefined;
|
|
25
34
|
const packageJsonPath = path.resolve(__dirname, '..', '..', 'package.json');
|
|
35
|
+
const projectDirectory = workspaceProject?.root || '.';
|
|
36
|
+
const projectPackageJson = tree.readJson(path.posix.join(projectDirectory, 'package.json'));
|
|
26
37
|
const depsInfo = getO3rPeerDeps(packageJsonPath);
|
|
27
38
|
const dependencies = depsInfo.o3rPeerDeps.reduce((acc, dep) => {
|
|
28
39
|
acc[dep] = {
|
|
@@ -34,22 +45,23 @@ function ngAddFn(options) {
|
|
|
34
45
|
};
|
|
35
46
|
return acc;
|
|
36
47
|
}, getPackageInstallConfig(packageJsonPath, tree, options.projectName, false, !!options.exactO3rVersion));
|
|
37
|
-
|
|
38
|
-
|
|
39
|
-
|
|
40
|
-
|
|
41
|
-
|
|
42
|
-
|
|
43
|
-
|
|
44
|
-
};
|
|
45
|
-
});
|
|
48
|
+
const externalDependenciesInfo = getExternalDependenciesInfo({
|
|
49
|
+
devDependenciesToInstall,
|
|
50
|
+
dependenciesToInstall,
|
|
51
|
+
projectType: workspaceProject?.projectType,
|
|
52
|
+
projectPackageJson,
|
|
53
|
+
o3rPackageJsonPath: packageJsonPath
|
|
54
|
+
}, context.logger);
|
|
46
55
|
return (0, schematics_1.chain)([
|
|
47
56
|
// optional custom action dedicated to this module
|
|
48
57
|
options.skipLinter ? (0, schematics_1.noop)() : applyEsLintFix(),
|
|
49
58
|
// add the missing Otter modules in the current project
|
|
50
59
|
setupDependencies({
|
|
51
60
|
projectName: options.projectName,
|
|
52
|
-
dependencies
|
|
61
|
+
dependencies: {
|
|
62
|
+
...dependencies,
|
|
63
|
+
...externalDependenciesInfo
|
|
64
|
+
},
|
|
53
65
|
ngAddToRun: depsInfo.o3rPeerDeps
|
|
54
66
|
})
|
|
55
67
|
]);
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"index.js","sourceRoot":"","sources":["../../../schematics/ng-add/index.ts"],"names":[],"mappings":";;;AAAA,kCAAkC;AAClC,2DAIoC;
|
|
1
|
+
{"version":3,"file":"index.js","sourceRoot":"","sources":["../../../schematics/ng-add/index.ts"],"names":[],"mappings":";;;AAAA,kCAAkC;AAClC,2DAIoC;AAQpC;;GAEG;AACH,MAAM,qBAAqB,GAAG;IAC5B,cAAc;IACd,aAAa;IACb,iBAAiB;IACjB,MAAM;CACP,CAAC;AAEF;;GAEG;AACH,MAAM,wBAAwB,GAAa,EAC1C,CAAC;AAEF,MAAM,0BAA0B,GAAG,CAAC,MAA2C,EAAE,EAAE,CAAC,CAAC,MAAW,EAAE,EAAE;IAClG,MAAM,CAAC,KAAK,CAAC;;8CAE+B,CAAC,CAAC;IAC9C,MAAM,MAAM,CAAC;AACf,CAAC,CAAC;AAEF;;;GAGG;AACH,SAAS,OAAO,CAAC,OAA8B;IAC7C,OAAO,KAAK,EAAE,IAAI,EAAE,OAAO,EAAE,EAAE;QAC7B,mFAAmF;QACnF,MAAM,EACJ,uBAAuB,EACvB,cAAc,EACd,iBAAiB,EACjB,cAAc,EACd,8BAA8B,EAC9B,kBAAkB,EAClB,2BAA2B,EAC5B,GAAG,2CAAa,iBAAiB,EAAC,CAAC;QAEpC,MAAM,gBAAgB,GAAG,OAAO,CAAC,WAAW,CAAC,CAAC,CAAC,kBAAkB,CAAC,IAAI,CAAC,EAAE,QAAQ,CAAC,OAAO,CAAC,WAAW,CAAC,CAAC,CAAC,CAAC,SAAS,CAAC;QACnH,MAAM,e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