@tsed/cli-plugin-passport 7.0.0-beta.1 → 7.0.0-beta.3
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/lib/esm/templates/protocol.template.js +9 -0
- package/lib/types/templates/generic.protocol.template.d.ts +1 -0
- package/lib/types/templates/passport.discord.protocol.template.d.ts +1 -0
- package/lib/types/templates/passport.facebook.protocol.template.d.ts +1 -0
- package/lib/types/templates/passport.http.protocol.template.d.ts +1 -0
- package/lib/types/templates/passport.jwt.protocol.template.d.ts +1 -0
- package/lib/types/templates/passport.local.protocol.template.d.ts +1 -0
- package/lib/types/templates/protocol.template.d.ts +1 -0
- package/package.json +4 -4
|
@@ -2,11 +2,20 @@ import { defineTemplate, ProjectClient, render } from "@tsed/cli";
|
|
|
2
2
|
import { inject } from "@tsed/di";
|
|
3
3
|
import { PassportClient } from "../services/PassportClient.js";
|
|
4
4
|
import { ProjectPackageJson } from "@tsed/cli-core";
|
|
5
|
+
import { s } from "@tsed/schema";
|
|
5
6
|
export default defineTemplate({
|
|
6
7
|
id: "protocol",
|
|
7
8
|
label: "Passport Protocol",
|
|
8
9
|
fileName: "{{symbolName}}.protocol",
|
|
9
10
|
outputDir: "{{srcDir}}/protocols",
|
|
11
|
+
schema: s.object({
|
|
12
|
+
passportPackage: s
|
|
13
|
+
.string()
|
|
14
|
+
.customKey("x-choices", () => {
|
|
15
|
+
return inject(PassportClient).getChoices();
|
|
16
|
+
})
|
|
17
|
+
.description("Passport package selected to generate the template")
|
|
18
|
+
}),
|
|
10
19
|
prompts() {
|
|
11
20
|
return [
|
|
12
21
|
{
|
|
@@ -10,6 +10,7 @@ declare const _default: import("@tsed/di").FactoryTokenProvider<{
|
|
|
10
10
|
hidden?: boolean;
|
|
11
11
|
preserveCase?: boolean;
|
|
12
12
|
preserveDirectory?: boolean;
|
|
13
|
+
schema?: import("@tsed/schema").JsonSchema;
|
|
13
14
|
render(symbolName: string, data: GenerateCmdContext): Promise<string | undefined | import("@tsed/cli").TemplateRenderReturnType> | string | undefined | import("@tsed/cli").TemplateRenderReturnType;
|
|
14
15
|
prompts?(data: GenerateCmdContext): import("@tsed/cli-core").QuestionOptions<GenerateCmdContext>[] | Promise<import("@tsed/cli-core").QuestionOptions<GenerateCmdContext>[]>;
|
|
15
16
|
hooks?: import("@tsed/di").ProviderOpts["hooks"];
|
|
@@ -10,6 +10,7 @@ declare const _default: import("@tsed/di").FactoryTokenProvider<{
|
|
|
10
10
|
hidden?: boolean;
|
|
11
11
|
preserveCase?: boolean;
|
|
12
12
|
preserveDirectory?: boolean;
|
|
13
|
+
schema?: import("@tsed/schema").JsonSchema;
|
|
13
14
|
render(symbolName: string, data: GenerateCmdContext): Promise<string | undefined | import("@tsed/cli").TemplateRenderReturnType> | string | undefined | import("@tsed/cli").TemplateRenderReturnType;
|
|
14
15
|
prompts?(data: GenerateCmdContext): import("@tsed/cli-core").QuestionOptions<GenerateCmdContext>[] | Promise<import("@tsed/cli-core").QuestionOptions<GenerateCmdContext>[]>;
|
|
15
16
|
hooks?: import("@tsed/di").ProviderOpts["hooks"];
|
|
@@ -10,6 +10,7 @@ declare const _default: import("@tsed/di").FactoryTokenProvider<{
|
|
|
10
10
|
hidden?: boolean;
|
|
11
11
|
preserveCase?: boolean;
|
|
12
12
|
preserveDirectory?: boolean;
|
|
13
|
+
schema?: import("@tsed/schema").JsonSchema;
|
|
13
14
|
render(symbolName: string, data: GenerateCmdContext): Promise<string | undefined | import("@tsed/cli").TemplateRenderReturnType> | string | undefined | import("@tsed/cli").TemplateRenderReturnType;
|
|
14
15
|
prompts?(data: GenerateCmdContext): import("@tsed/cli-core").QuestionOptions<GenerateCmdContext>[] | Promise<import("@tsed/cli-core").QuestionOptions<GenerateCmdContext>[]>;
|
|
15
16
|
hooks?: import("@tsed/di").ProviderOpts["hooks"];
|
|
@@ -10,6 +10,7 @@ declare const _default: import("@tsed/di").FactoryTokenProvider<{
|
|
|
10
10
|
hidden?: boolean;
|
|
11
11
|
preserveCase?: boolean;
|
|
12
12
|
preserveDirectory?: boolean;
|
|
13
|
+
schema?: import("@tsed/schema").JsonSchema;
|
|
13
14
|
render(symbolName: string, data: GenerateCmdContext): Promise<string | undefined | import("@tsed/cli").TemplateRenderReturnType> | string | undefined | import("@tsed/cli").TemplateRenderReturnType;
|
|
14
15
|
prompts?(data: GenerateCmdContext): import("@tsed/cli-core").QuestionOptions<GenerateCmdContext>[] | Promise<import("@tsed/cli-core").QuestionOptions<GenerateCmdContext>[]>;
|
|
15
16
|
hooks?: import("@tsed/di").ProviderOpts["hooks"];
|
|
@@ -10,6 +10,7 @@ declare const _default: import("@tsed/di").FactoryTokenProvider<{
|
|
|
10
10
|
hidden?: boolean;
|
|
11
11
|
preserveCase?: boolean;
|
|
12
12
|
preserveDirectory?: boolean;
|
|
13
|
+
schema?: import("@tsed/schema").JsonSchema;
|
|
13
14
|
render(symbolName: string, data: GenerateCmdContext): Promise<string | undefined | import("@tsed/cli").TemplateRenderReturnType> | string | undefined | import("@tsed/cli").TemplateRenderReturnType;
|
|
14
15
|
prompts?(data: GenerateCmdContext): import("@tsed/cli-core").QuestionOptions<GenerateCmdContext>[] | Promise<import("@tsed/cli-core").QuestionOptions<GenerateCmdContext>[]>;
|
|
15
16
|
hooks?: import("@tsed/di").ProviderOpts["hooks"];
|
|
@@ -10,6 +10,7 @@ declare const _default: import("@tsed/di").FactoryTokenProvider<{
|
|
|
10
10
|
hidden?: boolean;
|
|
11
11
|
preserveCase?: boolean;
|
|
12
12
|
preserveDirectory?: boolean;
|
|
13
|
+
schema?: import("@tsed/schema").JsonSchema;
|
|
13
14
|
render(symbolName: string, data: GenerateCmdContext): Promise<string | undefined | import("@tsed/cli").TemplateRenderReturnType> | string | undefined | import("@tsed/cli").TemplateRenderReturnType;
|
|
14
15
|
prompts?(data: GenerateCmdContext): import("@tsed/cli-core").QuestionOptions<GenerateCmdContext>[] | Promise<import("@tsed/cli-core").QuestionOptions<GenerateCmdContext>[]>;
|
|
15
16
|
hooks?: import("@tsed/di").ProviderOpts["hooks"];
|
|
@@ -20,6 +20,7 @@ declare const _default: import("@tsed/di").FactoryTokenProvider<{
|
|
|
20
20
|
hidden?: boolean;
|
|
21
21
|
preserveCase?: boolean;
|
|
22
22
|
preserveDirectory?: boolean;
|
|
23
|
+
schema?: import("@tsed/schema").JsonSchema;
|
|
23
24
|
render(symbolName: string, data: GenerateCmdContext): Promise<string | undefined | import("@tsed/cli").TemplateRenderReturnType> | string | undefined | import("@tsed/cli").TemplateRenderReturnType;
|
|
24
25
|
prompts?(data: GenerateCmdContext): import("@tsed/cli-core").QuestionOptions<GenerateCmdContext>[] | Promise<import("@tsed/cli-core").QuestionOptions<GenerateCmdContext>[]>;
|
|
25
26
|
hooks?: import("@tsed/di").ProviderOpts["hooks"];
|
package/package.json
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@tsed/cli-plugin-passport",
|
|
3
3
|
"description": "Ts.ED CLI plugin. Add Passport.js support",
|
|
4
|
-
"version": "7.0.0-beta.
|
|
4
|
+
"version": "7.0.0-beta.3",
|
|
5
5
|
"type": "module",
|
|
6
6
|
"main": "./lib/esm/index.js",
|
|
7
7
|
"source": "./src/index.ts",
|
|
@@ -26,9 +26,9 @@
|
|
|
26
26
|
"tslib": "2.7.0"
|
|
27
27
|
},
|
|
28
28
|
"devDependencies": {
|
|
29
|
-
"@tsed/cli": "7.0.0-beta.
|
|
30
|
-
"@tsed/cli-core": "7.0.0-beta.
|
|
31
|
-
"@tsed/typescript": "7.0.0-beta.
|
|
29
|
+
"@tsed/cli": "7.0.0-beta.3",
|
|
30
|
+
"@tsed/cli-core": "7.0.0-beta.3",
|
|
31
|
+
"@tsed/typescript": "7.0.0-beta.3",
|
|
32
32
|
"@types/change-case": "^2.3.1",
|
|
33
33
|
"cross-env": "7.0.3",
|
|
34
34
|
"typescript": "5.6.2",
|