fix(nest): add missing resource generator option (#8310)
Co-authored-by: hoonoh <hoonoh@users.noreply.github.com>
This commit is contained in:
parent
a7a7c55ff5
commit
f30b8a318d
@ -2,6 +2,7 @@ import type { Tree } from '@nrwl/devkit';
|
||||
import { convertNxGenerator } from '@nrwl/devkit';
|
||||
import type {
|
||||
NestGeneratorWithLanguageOption,
|
||||
NestGeneratorWithResourceOption,
|
||||
NestGeneratorWithTestOption,
|
||||
NormalizedOptions,
|
||||
} from '../utils';
|
||||
@ -12,7 +13,8 @@ import {
|
||||
} from '../utils';
|
||||
|
||||
export type ResourceGeneratorOptions = NestGeneratorWithLanguageOption &
|
||||
NestGeneratorWithTestOption;
|
||||
NestGeneratorWithTestOption &
|
||||
NestGeneratorWithResourceOption;
|
||||
|
||||
export function resourceGenerator(
|
||||
tree: Tree,
|
||||
|
||||
@ -16,6 +16,12 @@ export type NestSchematic =
|
||||
| 'resolver'
|
||||
| 'resource'
|
||||
| 'service';
|
||||
export type TransportLayer =
|
||||
| 'rest'
|
||||
| 'graphql-code-first'
|
||||
| 'graphql-schema-first'
|
||||
| 'microservice'
|
||||
| 'ws';
|
||||
|
||||
export type NestGeneratorOptions = {
|
||||
name: string;
|
||||
@ -33,6 +39,11 @@ export type NestGeneratorWithTestOption = NestGeneratorOptions & {
|
||||
unitTestRunner?: UnitTestRunner;
|
||||
};
|
||||
|
||||
export type NestGeneratorWithResourceOption = NestGeneratorOptions & {
|
||||
type?: TransportLayer;
|
||||
crud?: boolean;
|
||||
};
|
||||
|
||||
export type NormalizedOptions = {
|
||||
name: string;
|
||||
sourceRoot: string;
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user