Skip to content

Commit f8e5ade

Browse files
committed
fix(cli-plugin-oidc): simplify module definition and add missing ts-morph dependency
- Replaced `@Module` decorator with `injectable` for cleaner imports management. - Added `ts-morph` as a dependency to package.json.
1 parent b77cd0c commit f8e5ade

3 files changed

Lines changed: 25 additions & 11 deletions

File tree

packages/cli-plugin-oidc-provider/package.json

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -33,6 +33,7 @@
3333
"@tsed/cli-core": "workspace:*",
3434
"@tsed/typescript": "workspace:*",
3535
"cross-env": "7.0.3",
36+
"ts-morph": "^27.0.2",
3637
"typescript": "5.6.2",
3738
"vitest": "3.2.4"
3839
},

packages/cli-plugin-oidc-provider/src/CliPluginOidcProviderModule.ts

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -2,12 +2,10 @@ import "./templates/index.template.js";
22

33
import type {RenderDataContext} from "@tsed/cli";
44
import {Module, ProjectPackageJson} from "@tsed/cli-core";
5+
import {injectable} from "@tsed/di";
56

67
import {OidcProviderInitHook} from "./hooks/OidcProviderInitHook.js";
78

8-
@Module({
9-
imports: [OidcProviderInitHook]
10-
})
119
export class CliPluginOidcProviderModule {
1210
$alterPackageJson(packageJson: ProjectPackageJson, data: RenderDataContext) {
1311
if (data.oidc) {
@@ -26,3 +24,5 @@ export class CliPluginOidcProviderModule {
2624
return packageJson;
2725
}
2826
}
27+
28+
injectable(CliPluginOidcProviderModule).imports([OidcProviderInitHook]);

yarn.lock

Lines changed: 21 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -2786,7 +2786,7 @@ __metadata:
27862786
languageName: node
27872787
linkType: hard
27882788

2789-
"@ts-morph/common@npm:0.28.0, @ts-morph/common@npm:~0.28.0":
2789+
"@ts-morph/common@npm:0.28.0":
27902790
version: 0.28.0
27912791
resolution: "@ts-morph/common@npm:0.28.0"
27922792
dependencies:
@@ -2797,6 +2797,17 @@ __metadata:
27972797
languageName: node
27982798
linkType: hard
27992799

2800+
"@ts-morph/common@npm:~0.28.1":
2801+
version: 0.28.1
2802+
resolution: "@ts-morph/common@npm:0.28.1"
2803+
dependencies:
2804+
minimatch: "npm:^10.0.1"
2805+
path-browserify: "npm:^1.0.1"
2806+
tinyglobby: "npm:^0.2.14"
2807+
checksum: 10/d5c6ed11cf046c186c7263c28c7e9b5fbefb61c65b99f66cfe6a3b249f70f3fbf116b5aace2980602a7ceabecdc399065d5a7f14aabe5475eb43fd573a3cc665
2808+
languageName: node
2809+
linkType: hard
2810+
28002811
"@tsconfig/node10@npm:^1.0.7":
28012812
version: 1.0.11
28022813
resolution: "@tsconfig/node10@npm:1.0.11"
@@ -2875,6 +2886,7 @@ __metadata:
28752886
rxjs: "npm:^7.8.1"
28762887
semver: "npm:^7.6.3"
28772888
split: "npm:^1.0.1"
2889+
ts-morph: "npm:^27.0.2"
28782890
tslib: "npm:^2.7.0"
28792891
tunnel: "npm:^0.0.6"
28802892
typescript: "npm:5.6.2"
@@ -2975,7 +2987,7 @@ __metadata:
29752987
read-pkg-up: "npm:^11.0.0"
29762988
rxjs: "npm:^7.8.1"
29772989
semver: "npm:^7.6.3"
2978-
ts-morph: "npm:27.0.0"
2990+
ts-morph: "npm:^27.0.2"
29792991
tslib: "npm:^2.7.0"
29802992
typescript: "npm:5.6.2"
29812993
vitest: "npm:3.2.4"
@@ -3061,6 +3073,7 @@ __metadata:
30613073
"@tsed/cli-core": "workspace:*"
30623074
"@tsed/typescript": "workspace:*"
30633075
cross-env: "npm:7.0.3"
3076+
ts-morph: "npm:^27.0.2"
30643077
tslib: "npm:2.7.0"
30653078
typescript: "npm:5.6.2"
30663079
vitest: "npm:3.2.4"
@@ -3288,7 +3301,7 @@ __metadata:
32883301
read-pkg-up: "npm:^11.0.0"
32893302
rxjs: "npm:^7.8.1"
32903303
semver: "npm:^7.6.3"
3291-
ts-morph: "npm:27.0.0"
3304+
ts-morph: "npm:^27.0.2"
32923305
tslib: "npm:^2.7.0"
32933306
typescript: "npm:5.6.2"
32943307
vitest: "npm:3.2.4"
@@ -16291,13 +16304,13 @@ __metadata:
1629116304
languageName: node
1629216305
linkType: hard
1629316306

16294-
"ts-morph@npm:27.0.0":
16295-
version: 27.0.0
16296-
resolution: "ts-morph@npm:27.0.0"
16307+
"ts-morph@npm:^27.0.2":
16308+
version: 27.0.2
16309+
resolution: "ts-morph@npm:27.0.2"
1629716310
dependencies:
16298-
"@ts-morph/common": "npm:~0.28.0"
16311+
"@ts-morph/common": "npm:~0.28.1"
1629916312
code-block-writer: "npm:^13.0.3"
16300-
checksum: 10/69da50b6aa2c548a52d74b2b2a80796babd22146ad883a152625faeb778f61e0f9711b889cdfe37eb87b9fd14ec19e43bc1f101d7239e56c97704ba7a749c4df
16313+
checksum: 10/b9bd8ed86d4b76ca23446d3f808787cfe95a3bcb2316769a2f3fa262ea9ab4043bb76bf8aef677f9be0d758576f074df2926e701a535f84fd21946fdbf465148
1630116314
languageName: node
1630216315
linkType: hard
1630316316

0 commit comments

Comments
 (0)