@ama-sdk/client-fetch 12.3.0-prerelease.48 → 12.3.0-prerelease.49
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": "@ama-sdk/client-fetch",
|
|
3
|
-
"version": "12.3.0-prerelease.
|
|
3
|
+
"version": "12.3.0-prerelease.49",
|
|
4
4
|
"publishConfig": {
|
|
5
5
|
"access": "public"
|
|
6
6
|
},
|
|
@@ -38,17 +38,18 @@
|
|
|
38
38
|
"build:builders": "tsc -b tsconfig.builders.json --pretty && yarn generate-cjs-manifest"
|
|
39
39
|
},
|
|
40
40
|
"dependencies": {
|
|
41
|
+
"@o3r/schematics": "^12.3.0-prerelease.49",
|
|
41
42
|
"@swc/helpers": "~0.5.0",
|
|
42
43
|
"ts-node": "~10.9.2",
|
|
43
44
|
"tslib": "^2.6.2",
|
|
44
45
|
"uuid": "^11.0.5"
|
|
45
46
|
},
|
|
46
47
|
"peerDependencies": {
|
|
47
|
-
"@ama-sdk/core": "^12.3.0-prerelease.
|
|
48
|
+
"@ama-sdk/core": "^12.3.0-prerelease.49",
|
|
48
49
|
"@angular-devkit/schematics": "^19.0.0",
|
|
49
50
|
"@angular/cli": "^19.0.0",
|
|
50
51
|
"@angular/common": "^19.0.0",
|
|
51
|
-
"@o3r/schematics": "^12.3.0-prerelease.
|
|
52
|
+
"@o3r/schematics": "^12.3.0-prerelease.49",
|
|
52
53
|
"@schematics/angular": "^19.0.0",
|
|
53
54
|
"isomorphic-fetch": "^3.0.0",
|
|
54
55
|
"typescript": "^5.5.4"
|
|
@@ -77,7 +78,7 @@
|
|
|
77
78
|
}
|
|
78
79
|
},
|
|
79
80
|
"devDependencies": {
|
|
80
|
-
"@ama-sdk/core": "^12.3.0-prerelease.
|
|
81
|
+
"@ama-sdk/core": "^12.3.0-prerelease.49",
|
|
81
82
|
"@angular-devkit/core": "~19.2.0",
|
|
82
83
|
"@angular-devkit/schematics": "~19.2.0",
|
|
83
84
|
"@angular/common": "~19.2.0",
|
|
@@ -85,10 +86,9 @@
|
|
|
85
86
|
"@eslint-community/eslint-plugin-eslint-comments": "^4.4.0",
|
|
86
87
|
"@nx/eslint-plugin": "~20.8.0",
|
|
87
88
|
"@nx/jest": "~20.8.0",
|
|
88
|
-
"@o3r/build-helpers": "^12.3.0-prerelease.
|
|
89
|
-
"@o3r/eslint-plugin": "^12.3.0-prerelease.
|
|
90
|
-
"@o3r/
|
|
91
|
-
"@o3r/test-helpers": "^12.3.0-prerelease.48",
|
|
89
|
+
"@o3r/build-helpers": "^12.3.0-prerelease.49",
|
|
90
|
+
"@o3r/eslint-plugin": "^12.3.0-prerelease.49",
|
|
91
|
+
"@o3r/test-helpers": "^12.3.0-prerelease.49",
|
|
92
92
|
"@schematics/angular": "~19.2.0",
|
|
93
93
|
"@stylistic/eslint-plugin": "~3.1.0",
|
|
94
94
|
"@stylistic/eslint-plugin-ts": "~3.1.0",
|
|
@@ -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;
|
|
1
|
+
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../schematics/ng-add/index.ts"],"names":[],"mappings":"AACA,OAAO,EAGL,IAAI,EACL,MAAM,4BAA4B,CAAC;AAkBpC,OAAO,KAAK,EACV,qBAAqB,EACtB,MAAM,UAAU,CAAC;AAmDlB;;;GAGG;AACH,eAAO,MAAM,KAAK,GAAI,SAAS,qBAAqB,SAA2C,CAAC"}
|
|
@@ -3,37 +3,30 @@ 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
|
+
const schematics_2 = require("@o3r/schematics");
|
|
6
7
|
const dependencies_1 = require("@schematics/angular/utility/dependencies");
|
|
7
8
|
const import_map_1 = require("./migration/import-map");
|
|
8
9
|
const devDependenciesToInstall = [];
|
|
9
|
-
const reportMissingSchematicsDep = (logger) => (reason) => {
|
|
10
|
-
logger.error(`[ERROR]: Adding @ama-sdk/client-fetch has failed.
|
|
11
|
-
If the error is related to missing @o3r dependencies you need to install '@o3r/schematics' as devDependency to be able to use this schematics. Please run 'ng add @o3r/schematics'.
|
|
12
|
-
Otherwise, use the error message as guidance.`);
|
|
13
|
-
throw reason;
|
|
14
|
-
};
|
|
15
10
|
/**
|
|
16
11
|
* Add SDk Fetch Client to an Otter Project
|
|
17
12
|
* @param options
|
|
18
13
|
*/
|
|
19
14
|
function ngAddFn(options) {
|
|
20
|
-
return
|
|
21
|
-
|
|
22
|
-
const { getPackageInstallConfig, applyEsLintFix, setupDependencies, getO3rPeerDeps, getProjectNewDependenciesTypes, getWorkspaceConfig, getExternalDependenciesVersionRange, updateImports } = await Promise.resolve().then(() => require('@o3r/schematics'));
|
|
23
|
-
const workspaceProject = options.projectName ? getWorkspaceConfig(tree)?.projects[options.projectName] : undefined;
|
|
15
|
+
return (tree, context) => {
|
|
16
|
+
const workspaceProject = options.projectName ? (0, schematics_2.getWorkspaceConfig)(tree)?.projects[options.projectName] : undefined;
|
|
24
17
|
const packageJsonPath = path.resolve(__dirname, '..', '..', 'package.json');
|
|
25
|
-
const depsInfo = getO3rPeerDeps(packageJsonPath);
|
|
18
|
+
const depsInfo = (0, schematics_2.getO3rPeerDeps)(packageJsonPath);
|
|
26
19
|
const dependencies = depsInfo.o3rPeerDeps.reduce((acc, dep) => {
|
|
27
20
|
acc[dep] = {
|
|
28
21
|
inManifest: [{
|
|
29
22
|
range: `${options.exactO3rVersion ? '' : '~'}${depsInfo.packageVersion}`,
|
|
30
|
-
types: getProjectNewDependenciesTypes(workspaceProject)
|
|
23
|
+
types: (0, schematics_2.getProjectNewDependenciesTypes)(workspaceProject)
|
|
31
24
|
}],
|
|
32
25
|
ngAddOptions: { exactO3rVersion: options.exactO3rVersion }
|
|
33
26
|
};
|
|
34
27
|
return acc;
|
|
35
|
-
}, getPackageInstallConfig(packageJsonPath, tree, options.projectName, false, !!options.exactO3rVersion));
|
|
36
|
-
Object.entries(getExternalDependenciesVersionRange(devDependenciesToInstall, packageJsonPath, context.logger))
|
|
28
|
+
}, (0, schematics_2.getPackageInstallConfig)(packageJsonPath, tree, options.projectName, false, !!options.exactO3rVersion));
|
|
29
|
+
Object.entries((0, schematics_2.getExternalDependenciesVersionRange)(devDependenciesToInstall, packageJsonPath, context.logger))
|
|
37
30
|
.forEach(([dep, range]) => {
|
|
38
31
|
dependencies[dep] = {
|
|
39
32
|
inManifest: [{
|
|
@@ -44,14 +37,14 @@ function ngAddFn(options) {
|
|
|
44
37
|
});
|
|
45
38
|
return (0, schematics_1.chain)([
|
|
46
39
|
// optional custom action dedicated to this module
|
|
47
|
-
options.skipLinter ? (0, schematics_1.noop)() : applyEsLintFix(),
|
|
40
|
+
options.skipLinter ? (0, schematics_1.noop)() : (0, schematics_2.applyEsLintFix)(),
|
|
48
41
|
// add the missing Otter modules in the current project
|
|
49
|
-
setupDependencies({
|
|
42
|
+
(0, schematics_2.setupDependencies)({
|
|
50
43
|
projectName: options.projectName,
|
|
51
44
|
dependencies,
|
|
52
45
|
ngAddToRun: depsInfo.o3rPeerDeps
|
|
53
46
|
}),
|
|
54
|
-
updateImports(import_map_1.mapMigrationFromCoreImports)
|
|
47
|
+
(0, schematics_2.updateImports)(import_map_1.mapMigrationFromCoreImports)
|
|
55
48
|
]);
|
|
56
49
|
};
|
|
57
50
|
}
|
|
@@ -59,9 +52,6 @@ function ngAddFn(options) {
|
|
|
59
52
|
* Add SDk Fetch Client to an Otter Project
|
|
60
53
|
* @param options
|
|
61
54
|
*/
|
|
62
|
-
const ngAdd = (options) =>
|
|
63
|
-
const { createOtterSchematic } = await Promise.resolve().then(() => require('@o3r/schematics')).catch(reportMissingSchematicsDep(logger));
|
|
64
|
-
return createOtterSchematic(ngAddFn)(options);
|
|
65
|
-
};
|
|
55
|
+
const ngAdd = (options) => (0, schematics_2.createOtterSchematic)(ngAddFn)(options);
|
|
66
56
|
exports.ngAdd = ngAdd;
|
|
67
57
|
//# sourceMappingURL=index.js.map
|