nitro-graphql 2.0.0-beta.37 → 2.0.0-beta.39
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/README.md +2 -2
- package/dist/cli/commands/generate.d.mts +26 -0
- package/dist/cli/commands/generate.mjs +196 -0
- package/dist/cli/commands/index.d.mts +4 -0
- package/dist/cli/commands/index.mjs +5 -0
- package/dist/cli/commands/init.d.mts +43 -0
- package/dist/cli/commands/init.mjs +191 -0
- package/dist/cli/commands/validate.d.mts +10 -0
- package/dist/cli/commands/validate.mjs +69 -0
- package/dist/cli/completions.d.mts +7 -0
- package/dist/cli/completions.mjs +34 -0
- package/dist/cli/config.d.mts +75 -0
- package/dist/cli/config.mjs +20 -0
- package/dist/cli/index.d.mts +24 -0
- package/dist/cli/index.mjs +253 -0
- package/dist/core/codegen/client.d.mts +23 -0
- package/dist/core/codegen/client.mjs +150 -0
- package/dist/core/codegen/document-loader.d.mts +10 -0
- package/dist/core/codegen/document-loader.mjs +18 -0
- package/dist/core/codegen/index.d.mts +8 -0
- package/dist/core/codegen/index.mjs +9 -0
- package/dist/{utils/codegen-plugin.d.mts → core/codegen/plugin.d.mts} +2 -2
- package/dist/{utils/codegen-plugin.mjs → core/codegen/plugin.mjs} +1 -1
- package/dist/core/codegen/runtime.d.mts +20 -0
- package/dist/core/codegen/runtime.mjs +60 -0
- package/dist/core/codegen/schema-loader.d.mts +28 -0
- package/dist/core/codegen/schema-loader.mjs +128 -0
- package/dist/core/codegen/server.d.mts +28 -0
- package/dist/core/codegen/server.mjs +143 -0
- package/dist/{codegen → core/codegen}/validation.d.mts +1 -1
- package/dist/{codegen → core/codegen}/validation.mjs +1 -1
- package/dist/core/config.d.mts +50 -0
- package/dist/core/config.mjs +82 -0
- package/dist/core/constants.d.mts +188 -0
- package/dist/core/constants.mjs +210 -0
- package/dist/core/index.d.mts +32 -0
- package/dist/core/index.mjs +26 -0
- package/dist/core/scanning/ast-scanner.d.mts +23 -0
- package/dist/core/scanning/ast-scanner.mjs +103 -0
- package/dist/core/scanning/common.d.mts +37 -0
- package/dist/core/scanning/common.mjs +60 -0
- package/dist/core/scanning/directives.d.mts +10 -0
- package/dist/core/scanning/directives.mjs +29 -0
- package/dist/core/scanning/documents.d.mts +21 -0
- package/dist/core/scanning/documents.mjs +43 -0
- package/dist/core/scanning/index.d.mts +7 -0
- package/dist/core/scanning/index.mjs +8 -0
- package/dist/core/scanning/resolvers.d.mts +10 -0
- package/dist/core/scanning/resolvers.mjs +58 -0
- package/dist/core/scanning/schemas.d.mts +14 -0
- package/dist/core/scanning/schemas.mjs +64 -0
- package/dist/{utils/schema-builder.d.mts → core/schema/builder.d.mts} +7 -2
- package/dist/{utils/schema-builder.mjs → core/schema/builder.mjs} +22 -3
- package/dist/{utils → core/schema}/federation.d.mts +10 -5
- package/dist/{utils → core/schema}/federation.mjs +1 -1
- package/dist/core/schema/index.d.mts +3 -0
- package/dist/core/schema/index.mjs +4 -0
- package/dist/core/types/adapter.d.mts +58 -0
- package/dist/core/types/codegen.d.mts +133 -0
- package/dist/core/types/config.d.mts +212 -0
- package/dist/{types → core/types}/define.d.mts +3 -7
- package/dist/core/types/index.d.mts +5 -0
- package/dist/core/types/scanning.d.mts +69 -0
- package/dist/core/types/scanning.mjs +1 -0
- package/dist/{utils → core/utils}/directive-parser.d.mts +21 -5
- package/dist/{utils → core/utils}/directive-parser.mjs +25 -36
- package/dist/{utils → core/utils}/errors.d.mts +8 -4
- package/dist/{utils → core/utils}/errors.mjs +8 -4
- package/dist/core/utils/file-io.d.mts +24 -0
- package/dist/core/utils/file-io.mjs +47 -0
- package/dist/{utils → core/utils}/imports.d.mts +1 -1
- package/dist/{utils → core/utils}/imports.mjs +1 -1
- package/dist/core/utils/index.d.mts +7 -0
- package/dist/core/utils/index.mjs +8 -0
- package/dist/core/utils/logger.d.mts +19 -0
- package/dist/core/utils/logger.mjs +38 -0
- package/dist/{utils → core/utils}/ofetch-templates.d.mts +1 -1
- package/dist/{utils → core/utils}/ofetch-templates.mjs +1 -1
- package/dist/core/validation/external-services.d.mts +11 -0
- package/dist/{utils/validation.mjs → core/validation/external-services.mjs} +3 -3
- package/dist/core/validation/index.d.mts +2 -0
- package/dist/core/validation/index.mjs +3 -0
- package/dist/define.d.mts +2 -4
- package/dist/define.mjs +1 -1
- package/dist/index.d.mts +6 -44
- package/dist/index.mjs +5 -62
- package/dist/nitro/adapter.d.mts +30 -0
- package/dist/nitro/adapter.mjs +97 -0
- package/dist/{utils → nitro}/apollo.d.mts +1 -1
- package/dist/{utils → nitro}/apollo.mjs +1 -1
- package/dist/nitro/codegen.d.mts +19 -0
- package/dist/nitro/codegen.mjs +141 -0
- package/dist/nitro/config.d.mts +52 -0
- package/dist/nitro/config.mjs +58 -0
- package/dist/nitro/index.d.mts +46 -0
- package/dist/nitro/index.mjs +65 -0
- package/dist/{utils/path-resolver.d.mts → nitro/paths.d.mts} +3 -19
- package/dist/{utils/path-resolver.mjs → nitro/paths.mjs} +2 -36
- package/dist/{rollup.d.mts → nitro/rollup.d.mts} +1 -1
- package/dist/{rollup.mjs → nitro/rollup.mjs} +11 -23
- package/dist/{routes → nitro/routes}/apollo-server.d.mts +1 -1
- package/dist/{routes → nitro/routes}/apollo-server.mjs +5 -5
- package/dist/{routes → nitro/routes}/debug-template.d.mts +1 -1
- package/dist/{routes → nitro/routes}/debug-template.mjs +1 -1
- package/dist/{routes → nitro/routes}/debug.d.mts +10 -16
- package/dist/{routes → nitro/routes}/debug.mjs +2 -2
- package/dist/{routes → nitro/routes}/graphql-yoga.d.mts +1 -1
- package/dist/{routes → nitro/routes}/graphql-yoga.mjs +3 -3
- package/dist/{routes → nitro/routes}/health.d.mts +1 -1
- package/dist/{routes → nitro/routes}/health.mjs +1 -1
- package/dist/nitro/setup/file-watcher.d.mts +16 -0
- package/dist/{setup → nitro/setup}/file-watcher.mjs +14 -18
- package/dist/{setup.d.mts → nitro/setup/logging.d.mts} +5 -6
- package/dist/nitro/setup/logging.mjs +66 -0
- package/dist/nitro/setup/rollup-integration.d.mts +16 -0
- package/dist/{setup → nitro/setup}/rollup-integration.mjs +2 -2
- package/dist/nitro/setup/routes.d.mts +10 -0
- package/dist/nitro/setup/routes.mjs +35 -0
- package/dist/nitro/setup/ts-config.d.mts +11 -0
- package/dist/{setup → nitro/setup}/ts-config.mjs +3 -3
- package/dist/nitro/setup.d.mts +12 -0
- package/dist/{setup.mjs → nitro/setup.mjs} +33 -100
- package/dist/{types/index.d.mts → nitro/types.d.mts} +125 -43
- package/dist/nitro/types.mjs +1 -0
- package/dist/nitro/virtual/generators.d.mts +31 -0
- package/dist/nitro/virtual/generators.mjs +193 -0
- package/dist/nitro/virtual/stubs.d.mts +20 -0
- package/dist/nitro/virtual/stubs.mjs +31 -0
- package/dist/{ecosystem/nuxt.d.mts → nuxt.d.mts} +1 -1
- package/dist/{ecosystem/nuxt.mjs → nuxt.mjs} +2 -2
- package/dist/{graphql/server.d.mts → stubs/index.d.mts} +5 -1
- package/dist/stubs/index.mjs +1 -0
- package/package.json +45 -42
- package/dist/codegen/client-types.d.mts +0 -13
- package/dist/codegen/client-types.mjs +0 -131
- package/dist/codegen/external-types.d.mts +0 -12
- package/dist/codegen/external-types.mjs +0 -88
- package/dist/codegen/index.d.mts +0 -18
- package/dist/codegen/index.mjs +0 -24
- package/dist/codegen/server-types.d.mts +0 -13
- package/dist/codegen/server-types.mjs +0 -64
- package/dist/config/defaults.mjs +0 -36
- package/dist/constants/scalars.mjs +0 -27
- package/dist/constants.mjs +0 -106
- package/dist/graphql/index.d.mts +0 -5
- package/dist/setup/graphql-scanner.mjs +0 -25
- package/dist/setup/scaffold-generator.mjs +0 -109
- package/dist/types/standard-schema.d.mts +0 -59
- package/dist/utils/client-codegen.d.mts +0 -41
- package/dist/utils/client-codegen.mjs +0 -277
- package/dist/utils/file-generator.d.mts +0 -37
- package/dist/utils/file-generator.mjs +0 -72
- package/dist/utils/file-writer.d.mts +0 -35
- package/dist/utils/file-writer.mjs +0 -32
- package/dist/utils/index.d.mts +0 -13
- package/dist/utils/index.mjs +0 -13
- package/dist/utils/layers.d.mts +0 -22
- package/dist/utils/layers.mjs +0 -28
- package/dist/utils/scanning/common.d.mts +0 -23
- package/dist/utils/scanning/common.mjs +0 -39
- package/dist/utils/scanning/directives.d.mts +0 -11
- package/dist/utils/scanning/directives.mjs +0 -43
- package/dist/utils/scanning/documents.d.mts +0 -15
- package/dist/utils/scanning/documents.mjs +0 -46
- package/dist/utils/scanning/index.d.mts +0 -6
- package/dist/utils/scanning/index.mjs +0 -7
- package/dist/utils/scanning/resolvers.d.mts +0 -11
- package/dist/utils/scanning/resolvers.mjs +0 -100
- package/dist/utils/scanning/schemas.d.mts +0 -15
- package/dist/utils/scanning/schemas.mjs +0 -29
- package/dist/utils/server-codegen.d.mts +0 -7
- package/dist/utils/server-codegen.mjs +0 -113
- package/dist/utils/type-generation.d.mts +0 -6
- package/dist/utils/type-generation.mjs +0 -7
- package/dist/utils/validation.d.mts +0 -11
- package/dist/virtual/debug-info.d.mts +0 -9
- package/dist/virtual/debug-info.mjs +0 -26
- package/dist/virtual/generators/config.d.mts +0 -22
- package/dist/virtual/generators/config.mjs +0 -36
- package/dist/virtual/generators/debug.d.mts +0 -14
- package/dist/virtual/generators/debug.mjs +0 -53
- package/dist/virtual/generators/directives.d.mts +0 -14
- package/dist/virtual/generators/directives.mjs +0 -52
- package/dist/virtual/generators/index.d.mts +0 -6
- package/dist/virtual/generators/index.mjs +0 -7
- package/dist/virtual/generators/resolvers.d.mts +0 -14
- package/dist/virtual/generators/resolvers.mjs +0 -55
- package/dist/virtual/generators/schemas.d.mts +0 -14
- package/dist/virtual/generators/schemas.mjs +0 -43
- package/dist/virtual/graphql-config.d.mts +0 -9
- package/dist/virtual/graphql-config.mjs +0 -10
- package/dist/virtual/module-config.d.mts +0 -9
- package/dist/virtual/module-config.mjs +0 -10
- package/dist/virtual/server-directives.d.mts +0 -11
- package/dist/virtual/server-directives.mjs +0 -10
- package/dist/virtual/server-resolvers.d.mts +0 -11
- package/dist/virtual/server-resolvers.mjs +0 -10
- package/dist/virtual/server-schemas.d.mts +0 -11
- package/dist/virtual/server-schemas.mjs +0 -10
- /package/dist/{graphql/index.mjs → core/types/adapter.mjs} +0 -0
- /package/dist/{graphql/server.mjs → core/types/codegen.mjs} +0 -0
- /package/dist/{types/define.mjs → core/types/config.mjs} +0 -0
- /package/dist/{types/index.mjs → core/types/define.mjs} +0 -0
- /package/dist/{types/standard-schema.mjs → core/types/index.mjs} +0 -0
|
@@ -0,0 +1,75 @@
|
|
|
1
|
+
import { GraphQLFramework } from "../core/constants.mjs";
|
|
2
|
+
import { CoreClientUtilsConfig, CoreCodegenConfig, CoreExternalService, CoreFederationConfig, CorePathsConfig, CoreScaffoldConfig, CoreSdkConfig, CoreSecurityConfig, CoreTypesConfig } from "../core/types/config.mjs";
|
|
3
|
+
import "../core/types/index.mjs";
|
|
4
|
+
|
|
5
|
+
//#region src/cli/config.d.ts
|
|
6
|
+
|
|
7
|
+
/**
|
|
8
|
+
* CLI configuration options
|
|
9
|
+
* Used when running nitro-graphql as a standalone CLI tool
|
|
10
|
+
*/
|
|
11
|
+
interface CLIConfig {
|
|
12
|
+
/** Root directory (defaults to current working directory) */
|
|
13
|
+
rootDir?: string;
|
|
14
|
+
/** Build output directory */
|
|
15
|
+
buildDir?: string;
|
|
16
|
+
/** Server GraphQL directory (defaults to 'server/graphql') */
|
|
17
|
+
serverDir?: string;
|
|
18
|
+
/** Client GraphQL directory (defaults to 'graphql') */
|
|
19
|
+
clientDir?: string;
|
|
20
|
+
/** Types output directory */
|
|
21
|
+
typesDir?: string;
|
|
22
|
+
/** GraphQL framework (defaults to 'graphql-yoga') */
|
|
23
|
+
framework?: GraphQLFramework;
|
|
24
|
+
/** Codegen configuration */
|
|
25
|
+
codegen?: CoreCodegenConfig;
|
|
26
|
+
/** Security configuration */
|
|
27
|
+
security?: CoreSecurityConfig;
|
|
28
|
+
/** External GraphQL services */
|
|
29
|
+
externalServices?: CoreExternalService[];
|
|
30
|
+
/** Apollo Federation configuration */
|
|
31
|
+
federation?: CoreFederationConfig;
|
|
32
|
+
/** Path configuration */
|
|
33
|
+
paths?: CorePathsConfig;
|
|
34
|
+
/** Scaffold file configuration */
|
|
35
|
+
scaffold?: false | CoreScaffoldConfig;
|
|
36
|
+
/** Type generation configuration */
|
|
37
|
+
types?: false | CoreTypesConfig;
|
|
38
|
+
/** SDK generation configuration */
|
|
39
|
+
sdk?: false | CoreSdkConfig;
|
|
40
|
+
/** Client utilities configuration */
|
|
41
|
+
clientUtils?: false | CoreClientUtilsConfig;
|
|
42
|
+
/** Patterns to ignore during scanning */
|
|
43
|
+
ignore?: string[];
|
|
44
|
+
/** Watch mode configuration */
|
|
45
|
+
watch?: {
|
|
46
|
+
/** Enable watch mode */
|
|
47
|
+
enabled?: boolean;
|
|
48
|
+
/** Debounce time in ms */
|
|
49
|
+
debounce?: number;
|
|
50
|
+
};
|
|
51
|
+
/**
|
|
52
|
+
* Runtime file generation
|
|
53
|
+
* Generates resolvers.ts, schema.ts for standalone server usage
|
|
54
|
+
*/
|
|
55
|
+
runtime?: boolean | {
|
|
56
|
+
/** Output directory for runtime files (defaults to '{buildDir}/runtime') */
|
|
57
|
+
outDir?: string;
|
|
58
|
+
/** What to include in generation */
|
|
59
|
+
include?: {
|
|
60
|
+
resolvers?: boolean;
|
|
61
|
+
schema?: boolean;
|
|
62
|
+
index?: boolean;
|
|
63
|
+
};
|
|
64
|
+
};
|
|
65
|
+
}
|
|
66
|
+
/**
|
|
67
|
+
* Define CLI configuration with type safety
|
|
68
|
+
*/
|
|
69
|
+
declare function defineConfig(config: CLIConfig): CLIConfig;
|
|
70
|
+
/**
|
|
71
|
+
* Default CLI configuration values
|
|
72
|
+
*/
|
|
73
|
+
declare const DEFAULT_CLI_CONFIG: CLIConfig;
|
|
74
|
+
//#endregion
|
|
75
|
+
export { CLIConfig, DEFAULT_CLI_CONFIG, defineConfig };
|
|
@@ -0,0 +1,20 @@
|
|
|
1
|
+
//#region src/cli/config.ts
|
|
2
|
+
/**
|
|
3
|
+
* Define CLI configuration with type safety
|
|
4
|
+
*/
|
|
5
|
+
function defineConfig(config) {
|
|
6
|
+
return config;
|
|
7
|
+
}
|
|
8
|
+
/**
|
|
9
|
+
* Default CLI configuration values
|
|
10
|
+
*/
|
|
11
|
+
const DEFAULT_CLI_CONFIG = {
|
|
12
|
+
framework: "graphql-yoga",
|
|
13
|
+
serverDir: "server/graphql",
|
|
14
|
+
clientDir: "graphql",
|
|
15
|
+
buildDir: ".graphql",
|
|
16
|
+
ignore: ["**/node_modules/**", "**/dist/**"]
|
|
17
|
+
};
|
|
18
|
+
|
|
19
|
+
//#endregion
|
|
20
|
+
export { DEFAULT_CLI_CONFIG, defineConfig };
|
|
@@ -0,0 +1,24 @@
|
|
|
1
|
+
#!/usr/bin/env node
|
|
2
|
+
import { CLIConfig, defineConfig } from "./config.mjs";
|
|
3
|
+
|
|
4
|
+
//#region src/cli/index.d.ts
|
|
5
|
+
|
|
6
|
+
/**
|
|
7
|
+
* CLI context with resolved configuration
|
|
8
|
+
*/
|
|
9
|
+
interface CLIContext {
|
|
10
|
+
config: Required<Pick<CLIConfig, 'rootDir' | 'buildDir' | 'serverDir' | 'clientDir' | 'typesDir' | 'framework' | 'ignore'>> & CLIConfig;
|
|
11
|
+
cwd: string;
|
|
12
|
+
}
|
|
13
|
+
/**
|
|
14
|
+
* Load CLI configuration from file or defaults
|
|
15
|
+
*/
|
|
16
|
+
declare function loadConfig(cwd?: string): Promise<CLIConfig>;
|
|
17
|
+
/**
|
|
18
|
+
* Create CLI context from configuration
|
|
19
|
+
*/
|
|
20
|
+
declare function createCLIContext(options?: {
|
|
21
|
+
cwd?: string;
|
|
22
|
+
}): Promise<CLIContext>;
|
|
23
|
+
//#endregion
|
|
24
|
+
export { type CLIConfig, CLIContext, createCLIContext, defineConfig, loadConfig };
|
|
@@ -0,0 +1,253 @@
|
|
|
1
|
+
#!/usr/bin/env node
|
|
2
|
+
import { LOG_TAG } from "../core/constants.mjs";
|
|
3
|
+
import { DEFAULT_CLI_CONFIG, defineConfig } from "./config.mjs";
|
|
4
|
+
import consola from "consola";
|
|
5
|
+
import { resolve } from "pathe";
|
|
6
|
+
import { existsSync } from "node:fs";
|
|
7
|
+
import { defineCommand, runMain } from "citty";
|
|
8
|
+
|
|
9
|
+
//#region src/cli/index.ts
|
|
10
|
+
const logger = consola.withTag(LOG_TAG);
|
|
11
|
+
/**
|
|
12
|
+
* Load CLI configuration from file or defaults
|
|
13
|
+
*/
|
|
14
|
+
async function loadConfig(cwd = process.cwd()) {
|
|
15
|
+
for (const file of [
|
|
16
|
+
"nitro-graphql.config.ts",
|
|
17
|
+
"nitro-graphql.config.js",
|
|
18
|
+
"nitro-graphql.config.mjs",
|
|
19
|
+
"graphql.config.ts"
|
|
20
|
+
]) {
|
|
21
|
+
const configPath = resolve(cwd, file);
|
|
22
|
+
if (existsSync(configPath)) try {
|
|
23
|
+
const module = await import(configPath);
|
|
24
|
+
const config = module.default || module;
|
|
25
|
+
logger.info(`Loaded config from ${file}`);
|
|
26
|
+
return {
|
|
27
|
+
...DEFAULT_CLI_CONFIG,
|
|
28
|
+
...config
|
|
29
|
+
};
|
|
30
|
+
} catch (error) {
|
|
31
|
+
logger.warn(`Failed to load config from ${file}:`, error);
|
|
32
|
+
}
|
|
33
|
+
}
|
|
34
|
+
logger.debug("Using default configuration");
|
|
35
|
+
return { ...DEFAULT_CLI_CONFIG };
|
|
36
|
+
}
|
|
37
|
+
/**
|
|
38
|
+
* Create CLI context from configuration
|
|
39
|
+
*/
|
|
40
|
+
async function createCLIContext(options = {}) {
|
|
41
|
+
const cwd = options.cwd || process.cwd();
|
|
42
|
+
const config = await loadConfig(cwd);
|
|
43
|
+
const rootDir = config.rootDir ? resolve(cwd, config.rootDir) : cwd;
|
|
44
|
+
const buildDir = config.buildDir ? resolve(rootDir, config.buildDir) : resolve(rootDir, ".nitro-graphql");
|
|
45
|
+
const serverDir = config.serverDir ? resolve(rootDir, config.serverDir) : resolve(rootDir, "server/graphql");
|
|
46
|
+
const clientDir = config.clientDir ? resolve(rootDir, config.clientDir) : resolve(rootDir, "graphql");
|
|
47
|
+
const typesDir = config.typesDir ? resolve(rootDir, config.typesDir) : resolve(buildDir, "types");
|
|
48
|
+
return {
|
|
49
|
+
cwd,
|
|
50
|
+
config: {
|
|
51
|
+
...config,
|
|
52
|
+
rootDir,
|
|
53
|
+
buildDir,
|
|
54
|
+
serverDir,
|
|
55
|
+
clientDir,
|
|
56
|
+
typesDir,
|
|
57
|
+
framework: config.framework || "graphql-yoga",
|
|
58
|
+
ignore: config.ignore || ["**/node_modules/**", "**/dist/**"]
|
|
59
|
+
}
|
|
60
|
+
};
|
|
61
|
+
}
|
|
62
|
+
const generateCommand = defineCommand({
|
|
63
|
+
meta: {
|
|
64
|
+
name: "generate",
|
|
65
|
+
description: "Generate all GraphQL types"
|
|
66
|
+
},
|
|
67
|
+
args: {
|
|
68
|
+
cwd: {
|
|
69
|
+
type: "string",
|
|
70
|
+
description: "Set working directory"
|
|
71
|
+
},
|
|
72
|
+
silent: {
|
|
73
|
+
type: "boolean",
|
|
74
|
+
alias: "s",
|
|
75
|
+
description: "Suppress output"
|
|
76
|
+
},
|
|
77
|
+
watch: {
|
|
78
|
+
type: "boolean",
|
|
79
|
+
alias: "w",
|
|
80
|
+
description: "Watch mode"
|
|
81
|
+
},
|
|
82
|
+
runtime: {
|
|
83
|
+
type: "boolean",
|
|
84
|
+
alias: "r",
|
|
85
|
+
description: "Generate runtime files (resolvers.ts, schema.ts)"
|
|
86
|
+
}
|
|
87
|
+
},
|
|
88
|
+
async run({ args }) {
|
|
89
|
+
const ctx = await createCLIContext({ cwd: args.cwd });
|
|
90
|
+
const silent = Boolean(args.silent);
|
|
91
|
+
const watch = Boolean(args.watch);
|
|
92
|
+
const runtime = Boolean(args.runtime) || Boolean(ctx.config.runtime);
|
|
93
|
+
if (!silent) logger.info("Generating GraphQL types...");
|
|
94
|
+
const { generateAll } = await import("./commands/generate.mjs");
|
|
95
|
+
await generateAll(ctx, {
|
|
96
|
+
silent,
|
|
97
|
+
watch,
|
|
98
|
+
runtime
|
|
99
|
+
});
|
|
100
|
+
if (!silent) logger.success("Type generation complete!");
|
|
101
|
+
}
|
|
102
|
+
});
|
|
103
|
+
const generateServerCommand = defineCommand({
|
|
104
|
+
meta: {
|
|
105
|
+
name: "generate:server",
|
|
106
|
+
description: "Generate server types only"
|
|
107
|
+
},
|
|
108
|
+
args: {
|
|
109
|
+
cwd: {
|
|
110
|
+
type: "string",
|
|
111
|
+
description: "Set working directory"
|
|
112
|
+
},
|
|
113
|
+
silent: {
|
|
114
|
+
type: "boolean",
|
|
115
|
+
alias: "s",
|
|
116
|
+
description: "Suppress output"
|
|
117
|
+
}
|
|
118
|
+
},
|
|
119
|
+
async run({ args }) {
|
|
120
|
+
const ctx = await createCLIContext({ cwd: args.cwd });
|
|
121
|
+
const silent = Boolean(args.silent);
|
|
122
|
+
if (!silent) logger.info("Generating server types...");
|
|
123
|
+
const { generateServer } = await import("./commands/generate.mjs");
|
|
124
|
+
await generateServer(ctx, { silent });
|
|
125
|
+
if (!silent) logger.success("Server type generation complete!");
|
|
126
|
+
}
|
|
127
|
+
});
|
|
128
|
+
const generateClientCommand = defineCommand({
|
|
129
|
+
meta: {
|
|
130
|
+
name: "generate:client",
|
|
131
|
+
description: "Generate client types only"
|
|
132
|
+
},
|
|
133
|
+
args: {
|
|
134
|
+
cwd: {
|
|
135
|
+
type: "string",
|
|
136
|
+
description: "Set working directory"
|
|
137
|
+
},
|
|
138
|
+
silent: {
|
|
139
|
+
type: "boolean",
|
|
140
|
+
alias: "s",
|
|
141
|
+
description: "Suppress output"
|
|
142
|
+
}
|
|
143
|
+
},
|
|
144
|
+
async run({ args }) {
|
|
145
|
+
const ctx = await createCLIContext({ cwd: args.cwd });
|
|
146
|
+
const silent = Boolean(args.silent);
|
|
147
|
+
if (!silent) logger.info("Generating client types...");
|
|
148
|
+
const { generateClient } = await import("./commands/generate.mjs");
|
|
149
|
+
await generateClient(ctx, { silent });
|
|
150
|
+
if (!silent) logger.success("Client type generation complete!");
|
|
151
|
+
}
|
|
152
|
+
});
|
|
153
|
+
const validateCommand = defineCommand({
|
|
154
|
+
meta: {
|
|
155
|
+
name: "validate",
|
|
156
|
+
description: "Validate GraphQL schemas"
|
|
157
|
+
},
|
|
158
|
+
args: { cwd: {
|
|
159
|
+
type: "string",
|
|
160
|
+
description: "Set working directory"
|
|
161
|
+
} },
|
|
162
|
+
async run({ args }) {
|
|
163
|
+
const ctx = await createCLIContext({ cwd: args.cwd });
|
|
164
|
+
logger.info("Validating GraphQL schemas...");
|
|
165
|
+
const { validate } = await import("./commands/validate.mjs");
|
|
166
|
+
if (await validate(ctx)) logger.success("Schema validation passed!");
|
|
167
|
+
else {
|
|
168
|
+
logger.error("Schema validation failed!");
|
|
169
|
+
process.exit(1);
|
|
170
|
+
}
|
|
171
|
+
}
|
|
172
|
+
});
|
|
173
|
+
const initCommand = defineCommand({
|
|
174
|
+
meta: {
|
|
175
|
+
name: "init",
|
|
176
|
+
description: "Initialize project structure or download a template"
|
|
177
|
+
},
|
|
178
|
+
args: {
|
|
179
|
+
projectName: {
|
|
180
|
+
type: "positional",
|
|
181
|
+
description: "Project name (directory to create)",
|
|
182
|
+
required: false
|
|
183
|
+
},
|
|
184
|
+
cwd: {
|
|
185
|
+
type: "string",
|
|
186
|
+
description: "Set working directory"
|
|
187
|
+
},
|
|
188
|
+
force: {
|
|
189
|
+
type: "boolean",
|
|
190
|
+
alias: "f",
|
|
191
|
+
description: "Force overwrite existing files"
|
|
192
|
+
},
|
|
193
|
+
template: {
|
|
194
|
+
type: "string",
|
|
195
|
+
alias: "t",
|
|
196
|
+
description: "Template to use (e.g., drizzle-orm, vite-react)"
|
|
197
|
+
},
|
|
198
|
+
list: {
|
|
199
|
+
type: "boolean",
|
|
200
|
+
alias: "l",
|
|
201
|
+
description: "List available templates"
|
|
202
|
+
}
|
|
203
|
+
},
|
|
204
|
+
async run({ args }) {
|
|
205
|
+
const { listTemplates, initFromTemplate, init } = await import("./commands/init.mjs");
|
|
206
|
+
if (args.list) {
|
|
207
|
+
listTemplates();
|
|
208
|
+
return;
|
|
209
|
+
}
|
|
210
|
+
if (args.template) {
|
|
211
|
+
const projectName = args.projectName || args.template;
|
|
212
|
+
logger.info(`Creating project "${projectName}" from template "${args.template}"...`);
|
|
213
|
+
await initFromTemplate(projectName, args.template, {
|
|
214
|
+
force: Boolean(args.force),
|
|
215
|
+
cwd: args.cwd || process.cwd()
|
|
216
|
+
});
|
|
217
|
+
logger.success("Project created successfully!");
|
|
218
|
+
return;
|
|
219
|
+
}
|
|
220
|
+
const ctx = await createCLIContext({ cwd: args.cwd });
|
|
221
|
+
logger.info("Initializing nitro-graphql project...");
|
|
222
|
+
await init(ctx, { force: Boolean(args.force) });
|
|
223
|
+
logger.success("Project initialized!");
|
|
224
|
+
}
|
|
225
|
+
});
|
|
226
|
+
const main = defineCommand({
|
|
227
|
+
meta: {
|
|
228
|
+
name: "nitro-graphql",
|
|
229
|
+
version: "2.0.0",
|
|
230
|
+
description: "GraphQL type generation CLI for Nitro"
|
|
231
|
+
},
|
|
232
|
+
subCommands: {
|
|
233
|
+
"generate": generateCommand,
|
|
234
|
+
"gen": generateCommand,
|
|
235
|
+
"g": generateCommand,
|
|
236
|
+
"generate:server": generateServerCommand,
|
|
237
|
+
"gen:server": generateServerCommand,
|
|
238
|
+
"generate:client": generateClientCommand,
|
|
239
|
+
"gen:client": generateClientCommand,
|
|
240
|
+
"validate": validateCommand,
|
|
241
|
+
"v": validateCommand,
|
|
242
|
+
"init": initCommand
|
|
243
|
+
}
|
|
244
|
+
});
|
|
245
|
+
async function run() {
|
|
246
|
+
const { initCompletions } = await import("./completions.mjs");
|
|
247
|
+
await initCompletions(main);
|
|
248
|
+
return runMain(main);
|
|
249
|
+
}
|
|
250
|
+
run();
|
|
251
|
+
|
|
252
|
+
//#endregion
|
|
253
|
+
export { createCLIContext, defineConfig, loadConfig };
|
|
@@ -0,0 +1,23 @@
|
|
|
1
|
+
import { ClientCodegenConfig, ClientCodegenInput, ClientCodegenResult, ExternalServiceCodegenConfig } from "../types/codegen.mjs";
|
|
2
|
+
import { loadGraphQLDocuments } from "./document-loader.mjs";
|
|
3
|
+
import { GraphQLLoadSchemaOptions, GraphQLTypeDefPointer, downloadAndSaveSchema, graphQLLoadSchemaSync, loadExternalSchema } from "./schema-loader.mjs";
|
|
4
|
+
import { Source } from "@graphql-tools/utils";
|
|
5
|
+
import { GraphQLSchema } from "graphql";
|
|
6
|
+
|
|
7
|
+
//#region src/core/codegen/client.d.ts
|
|
8
|
+
|
|
9
|
+
/**
|
|
10
|
+
* Default client codegen configuration
|
|
11
|
+
*/
|
|
12
|
+
declare const DEFAULT_CLIENT_CODEGEN_CONFIG: ClientCodegenConfig;
|
|
13
|
+
/**
|
|
14
|
+
* Generate client-side GraphQL types
|
|
15
|
+
* Pure function that generates TypeScript types from a GraphQL schema and documents
|
|
16
|
+
*/
|
|
17
|
+
declare function generateClientTypesCore(input: ClientCodegenInput): Promise<ClientCodegenResult | false>;
|
|
18
|
+
/**
|
|
19
|
+
* Generate client types for external GraphQL service
|
|
20
|
+
*/
|
|
21
|
+
declare function generateExternalClientTypesCore(service: ExternalServiceCodegenConfig, schema: GraphQLSchema, documents: Source[], virtualTypesPath?: string): Promise<ClientCodegenResult | false>;
|
|
22
|
+
//#endregion
|
|
23
|
+
export { DEFAULT_CLIENT_CODEGEN_CONFIG, type GraphQLLoadSchemaOptions, type GraphQLTypeDefPointer, downloadAndSaveSchema, generateClientTypesCore, generateExternalClientTypesCore, graphQLLoadSchemaSync, loadExternalSchema, loadGraphQLDocuments };
|
|
@@ -0,0 +1,150 @@
|
|
|
1
|
+
import { DEFAULT_GRAPHQL_SCALARS } from "../constants.mjs";
|
|
2
|
+
import { pluginContent } from "./plugin.mjs";
|
|
3
|
+
import { loadGraphQLDocuments } from "./document-loader.mjs";
|
|
4
|
+
import { downloadAndSaveSchema, graphQLLoadSchemaSync, loadExternalSchema } from "./schema-loader.mjs";
|
|
5
|
+
import { defu as defu$1 } from "defu";
|
|
6
|
+
import { codegen } from "@graphql-codegen/core";
|
|
7
|
+
import { preset } from "@graphql-codegen/import-types-preset";
|
|
8
|
+
import { plugin } from "@graphql-codegen/typed-document-node";
|
|
9
|
+
import { plugin as plugin$1 } from "@graphql-codegen/typescript";
|
|
10
|
+
import { plugin as plugin$2 } from "@graphql-codegen/typescript-generic-sdk";
|
|
11
|
+
import { plugin as plugin$3 } from "@graphql-codegen/typescript-operations";
|
|
12
|
+
import { printSchemaWithDirectives } from "@graphql-tools/utils";
|
|
13
|
+
import { parse } from "graphql";
|
|
14
|
+
|
|
15
|
+
//#region src/core/codegen/client.ts
|
|
16
|
+
/**
|
|
17
|
+
* Default client codegen configuration
|
|
18
|
+
*/
|
|
19
|
+
const DEFAULT_CLIENT_CODEGEN_CONFIG = {
|
|
20
|
+
emitLegacyCommonJSImports: false,
|
|
21
|
+
useTypeImports: true,
|
|
22
|
+
enumsAsTypes: true,
|
|
23
|
+
strictScalars: true,
|
|
24
|
+
maybeValue: "T | null | undefined",
|
|
25
|
+
inputMaybeValue: "T | undefined",
|
|
26
|
+
documentMode: "string",
|
|
27
|
+
pureMagicComment: true,
|
|
28
|
+
dedupeOperationSuffix: true,
|
|
29
|
+
rawRequest: true,
|
|
30
|
+
scalars: DEFAULT_GRAPHQL_SCALARS
|
|
31
|
+
};
|
|
32
|
+
/**
|
|
33
|
+
* Generate generic SDK content for schema-only generation
|
|
34
|
+
*/
|
|
35
|
+
function generateGenericSdkContent() {
|
|
36
|
+
return `// THIS FILE IS GENERATED, DO NOT EDIT!
|
|
37
|
+
/* eslint-disable eslint-comments/no-unlimited-disable */
|
|
38
|
+
/* tslint:disable */
|
|
39
|
+
/* eslint-disable */
|
|
40
|
+
/* prettier-ignore */
|
|
41
|
+
|
|
42
|
+
import type { GraphQLResolveInfo } from 'graphql'
|
|
43
|
+
export type RequireFields<T, K extends keyof T> = Omit<T, K> & { [P in K]-?: NonNullable<T[P]> }
|
|
44
|
+
|
|
45
|
+
export interface Requester<C = {}, E = unknown> {
|
|
46
|
+
<R, V>(doc: string, vars?: V, options?: C): Promise<R> | AsyncIterable<R>
|
|
47
|
+
}
|
|
48
|
+
|
|
49
|
+
export type Sdk = {
|
|
50
|
+
request: <R, V = Record<string, any>>(document: string, variables?: V) => Promise<R>
|
|
51
|
+
}
|
|
52
|
+
|
|
53
|
+
export function getSdk(requester: Requester): Sdk {
|
|
54
|
+
return {
|
|
55
|
+
request: <R, V = Record<string, any>>(document: string, variables?: V): Promise<R> => {
|
|
56
|
+
return requester<R, V>(document, variables)
|
|
57
|
+
}
|
|
58
|
+
}
|
|
59
|
+
}
|
|
60
|
+
`;
|
|
61
|
+
}
|
|
62
|
+
/**
|
|
63
|
+
* Generate client-side GraphQL types
|
|
64
|
+
* Pure function that generates TypeScript types from a GraphQL schema and documents
|
|
65
|
+
*/
|
|
66
|
+
async function generateClientTypesCore(input) {
|
|
67
|
+
const { schema, documents, config = {}, sdkConfig = {}, outputPath, serviceName, virtualTypesPath } = input;
|
|
68
|
+
if (documents.length === 0 && !serviceName) return false;
|
|
69
|
+
const mergedConfig = defu$1(DEFAULT_CLIENT_CODEGEN_CONFIG, config);
|
|
70
|
+
const mergedSdkConfig = defu$1(mergedConfig, sdkConfig);
|
|
71
|
+
try {
|
|
72
|
+
if (documents.length === 0) return {
|
|
73
|
+
types: await codegen({
|
|
74
|
+
filename: outputPath || "client-types.generated.ts",
|
|
75
|
+
schema: parse(printSchemaWithDirectives(schema)),
|
|
76
|
+
documents: [],
|
|
77
|
+
config: mergedConfig,
|
|
78
|
+
plugins: [{ pluginContent: {} }, { typescript: {} }],
|
|
79
|
+
pluginMap: {
|
|
80
|
+
pluginContent: { plugin: pluginContent },
|
|
81
|
+
typescript: { plugin: plugin$1 }
|
|
82
|
+
}
|
|
83
|
+
}),
|
|
84
|
+
sdk: generateGenericSdkContent()
|
|
85
|
+
};
|
|
86
|
+
const enableTypedDocumentNode = config.typedDocumentNode === true;
|
|
87
|
+
const plugins = [
|
|
88
|
+
{ pluginContent: {} },
|
|
89
|
+
{ typescript: {} },
|
|
90
|
+
{ typescriptOperations: {} }
|
|
91
|
+
];
|
|
92
|
+
const pluginMap = {
|
|
93
|
+
pluginContent: { plugin: pluginContent },
|
|
94
|
+
typescript: { plugin: plugin$1 },
|
|
95
|
+
typescriptOperations: { plugin: plugin$3 }
|
|
96
|
+
};
|
|
97
|
+
if (enableTypedDocumentNode) {
|
|
98
|
+
plugins.push({ typedDocumentNode: {} });
|
|
99
|
+
pluginMap.typedDocumentNode = { plugin };
|
|
100
|
+
}
|
|
101
|
+
const output = await codegen({
|
|
102
|
+
filename: outputPath || "client-types.generated.ts",
|
|
103
|
+
schema: parse(printSchemaWithDirectives(schema)),
|
|
104
|
+
documents: [...documents],
|
|
105
|
+
config: mergedConfig,
|
|
106
|
+
plugins,
|
|
107
|
+
pluginMap
|
|
108
|
+
});
|
|
109
|
+
const typesPath = virtualTypesPath || (serviceName ? `#graphql/client/${serviceName}` : "#graphql/client");
|
|
110
|
+
const sdkOutput = await preset.buildGeneratesSection({
|
|
111
|
+
baseOutputDir: outputPath || "client-types.generated.ts",
|
|
112
|
+
schema: parse(printSchemaWithDirectives(schema)),
|
|
113
|
+
documents: [...documents],
|
|
114
|
+
config: mergedSdkConfig,
|
|
115
|
+
presetConfig: { typesPath },
|
|
116
|
+
plugins: [{ pluginContent: {} }, { typescriptGenericSdk: {} }],
|
|
117
|
+
pluginMap: {
|
|
118
|
+
pluginContent: { plugin: pluginContent },
|
|
119
|
+
typescriptGenericSdk: { plugin: plugin$2 }
|
|
120
|
+
}
|
|
121
|
+
});
|
|
122
|
+
return {
|
|
123
|
+
types: output,
|
|
124
|
+
sdk: (await Promise.all(sdkOutput.map(async (config$1) => {
|
|
125
|
+
return {
|
|
126
|
+
file: config$1.filename,
|
|
127
|
+
content: await codegen(config$1)
|
|
128
|
+
};
|
|
129
|
+
})))[0]?.content || ""
|
|
130
|
+
};
|
|
131
|
+
} catch {
|
|
132
|
+
return false;
|
|
133
|
+
}
|
|
134
|
+
}
|
|
135
|
+
/**
|
|
136
|
+
* Generate client types for external GraphQL service
|
|
137
|
+
*/
|
|
138
|
+
async function generateExternalClientTypesCore(service, schema, documents, virtualTypesPath) {
|
|
139
|
+
return generateClientTypesCore({
|
|
140
|
+
schema,
|
|
141
|
+
documents,
|
|
142
|
+
config: service.codegen?.client || {},
|
|
143
|
+
sdkConfig: service.codegen?.clientSDK || {},
|
|
144
|
+
serviceName: service.name,
|
|
145
|
+
virtualTypesPath
|
|
146
|
+
});
|
|
147
|
+
}
|
|
148
|
+
|
|
149
|
+
//#endregion
|
|
150
|
+
export { DEFAULT_CLIENT_CODEGEN_CONFIG, downloadAndSaveSchema, generateClientTypesCore, generateExternalClientTypesCore, graphQLLoadSchemaSync, loadExternalSchema, loadGraphQLDocuments };
|
|
@@ -0,0 +1,10 @@
|
|
|
1
|
+
import { Source } from "@graphql-tools/utils";
|
|
2
|
+
|
|
3
|
+
//#region src/core/codegen/document-loader.d.ts
|
|
4
|
+
|
|
5
|
+
/**
|
|
6
|
+
* Load GraphQL documents from files
|
|
7
|
+
*/
|
|
8
|
+
declare function loadGraphQLDocuments(patterns: string | string[]): Promise<Source[]>;
|
|
9
|
+
//#endregion
|
|
10
|
+
export { loadGraphQLDocuments };
|
|
@@ -0,0 +1,18 @@
|
|
|
1
|
+
import { GraphQLFileLoader } from "@graphql-tools/graphql-file-loader";
|
|
2
|
+
import { loadDocuments } from "@graphql-tools/load";
|
|
3
|
+
|
|
4
|
+
//#region src/core/codegen/document-loader.ts
|
|
5
|
+
/**
|
|
6
|
+
* Load GraphQL documents from files
|
|
7
|
+
*/
|
|
8
|
+
async function loadGraphQLDocuments(patterns) {
|
|
9
|
+
try {
|
|
10
|
+
return await loadDocuments(patterns, { loaders: [new GraphQLFileLoader()] });
|
|
11
|
+
} catch (e) {
|
|
12
|
+
if ((e.message || "").includes("Unable to find any GraphQL type definitions for the following pointers:")) return [];
|
|
13
|
+
throw e;
|
|
14
|
+
}
|
|
15
|
+
}
|
|
16
|
+
|
|
17
|
+
//#endregion
|
|
18
|
+
export { loadGraphQLDocuments };
|
|
@@ -0,0 +1,8 @@
|
|
|
1
|
+
import { loadGraphQLDocuments } from "./document-loader.mjs";
|
|
2
|
+
import { GraphQLLoadSchemaOptions, GraphQLTypeDefPointer, downloadAndSaveSchema, graphQLLoadSchemaSync, loadExternalSchema } from "./schema-loader.mjs";
|
|
3
|
+
import { DEFAULT_CLIENT_CODEGEN_CONFIG, generateClientTypesCore, generateExternalClientTypesCore } from "./client.mjs";
|
|
4
|
+
import { GENERATED_FILE_HEADER, pluginContent } from "./plugin.mjs";
|
|
5
|
+
import { generateResolverModule, generateRuntimeIndex, generateSchemaModule } from "./runtime.mjs";
|
|
6
|
+
import { DEFAULT_SERVER_CODEGEN_CONFIG, generateServerTypesCore, generateTypes } from "./server.mjs";
|
|
7
|
+
import { validateNoDuplicateTypes } from "./validation.mjs";
|
|
8
|
+
export { DEFAULT_CLIENT_CODEGEN_CONFIG, DEFAULT_SERVER_CODEGEN_CONFIG, GENERATED_FILE_HEADER, type GraphQLLoadSchemaOptions, type GraphQLTypeDefPointer, downloadAndSaveSchema, generateClientTypesCore, generateExternalClientTypesCore, generateResolverModule, generateRuntimeIndex, generateSchemaModule, generateServerTypesCore, generateTypes, graphQLLoadSchemaSync, loadExternalSchema, loadGraphQLDocuments, pluginContent, validateNoDuplicateTypes };
|
|
@@ -0,0 +1,9 @@
|
|
|
1
|
+
import { GENERATED_FILE_HEADER, pluginContent } from "./plugin.mjs";
|
|
2
|
+
import { loadGraphQLDocuments } from "./document-loader.mjs";
|
|
3
|
+
import { downloadAndSaveSchema, graphQLLoadSchemaSync, loadExternalSchema } from "./schema-loader.mjs";
|
|
4
|
+
import { DEFAULT_CLIENT_CODEGEN_CONFIG, generateClientTypesCore, generateExternalClientTypesCore } from "./client.mjs";
|
|
5
|
+
import { generateResolverModule, generateRuntimeIndex, generateSchemaModule } from "./runtime.mjs";
|
|
6
|
+
import { DEFAULT_SERVER_CODEGEN_CONFIG, generateServerTypesCore, generateTypes } from "./server.mjs";
|
|
7
|
+
import { validateNoDuplicateTypes } from "./validation.mjs";
|
|
8
|
+
|
|
9
|
+
export { DEFAULT_CLIENT_CODEGEN_CONFIG, DEFAULT_SERVER_CODEGEN_CONFIG, GENERATED_FILE_HEADER, downloadAndSaveSchema, generateClientTypesCore, generateExternalClientTypesCore, generateResolverModule, generateRuntimeIndex, generateSchemaModule, generateServerTypesCore, generateTypes, graphQLLoadSchemaSync, loadExternalSchema, loadGraphQLDocuments, pluginContent, validateNoDuplicateTypes };
|
|
@@ -1,7 +1,7 @@
|
|
|
1
|
-
import { GraphQLSchema } from "graphql";
|
|
2
1
|
import { Source } from "@graphql-tools/utils";
|
|
2
|
+
import { GraphQLSchema } from "graphql";
|
|
3
3
|
|
|
4
|
-
//#region src/
|
|
4
|
+
//#region src/core/codegen/plugin.d.ts
|
|
5
5
|
|
|
6
6
|
/**
|
|
7
7
|
* Plugin to add prepend comments to generated files
|
|
@@ -0,0 +1,20 @@
|
|
|
1
|
+
import { ScannedResolver } from "../types/scanning.mjs";
|
|
2
|
+
import "../types/index.mjs";
|
|
3
|
+
|
|
4
|
+
//#region src/core/codegen/runtime.d.ts
|
|
5
|
+
|
|
6
|
+
/**
|
|
7
|
+
* Generate resolver module code
|
|
8
|
+
* Outputs Nitro-compatible format with { resolver: ... } wrapper
|
|
9
|
+
*/
|
|
10
|
+
declare function generateResolverModule(resolvers: ScannedResolver[], baseDir: string): string;
|
|
11
|
+
/**
|
|
12
|
+
* Generate schema module code
|
|
13
|
+
*/
|
|
14
|
+
declare function generateSchemaModule(schemaString: string): string;
|
|
15
|
+
/**
|
|
16
|
+
* Generate runtime index module
|
|
17
|
+
*/
|
|
18
|
+
declare function generateRuntimeIndex(): string;
|
|
19
|
+
//#endregion
|
|
20
|
+
export { generateResolverModule, generateRuntimeIndex, generateSchemaModule };
|