Skip to content

Commit 4c6340a

Browse files
committed
docs(@schematics/angular): correct generated file name examples in name descriptions
The `name` option descriptions of the directive, service, enum, interface, pipe, guard, interceptor and resolver schematics showed file names that include the type suffix, such as `my-directive.directive.ts` and `my-pipe.pipe.ts`. By default, these schematics no longer add the type to the file name, and the pipe, guard, interceptor and resolver schematics use `-` as the type separator. Update the examples to match the default output.
1 parent 9469dcd commit 4c6340a

8 files changed

Lines changed: 8 additions & 8 deletions

File tree

‎packages/schematics/angular/directive/schema.json‎

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -8,7 +8,7 @@
88
"properties": {
99
"name": {
1010
"type": "string",
11-
"description": "The name for the new directive. This will be used to create the directive's class and spec files (e.g., `my-directive.directive.ts` and `my-directive.directive.spec.ts`).",
11+
"description": "The name for the new directive. This will be used to create the directive's class and spec files (e.g., `my-directive.ts` and `my-directive.spec.ts`).",
1212
"$default": {
1313
"$source": "argv",
1414
"index": 0

‎packages/schematics/angular/enum/schema.json‎

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -8,7 +8,7 @@
88
"properties": {
99
"name": {
1010
"type": "string",
11-
"description": "The name for the new enum. This will be used to create the enum file (e.g., `my-enum.enum.ts`).",
11+
"description": "The name for the new enum. This will be used to create the enum file (e.g., `my-enum.ts`).",
1212
"$default": {
1313
"$source": "argv",
1414
"index": 0

‎packages/schematics/angular/guard/schema.json‎

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -8,7 +8,7 @@
88
"properties": {
99
"name": {
1010
"type": "string",
11-
"description": "The name for the new route guard. This will be used to create the guard's class and spec files (e.g., `my-guard.guard.ts` and `my-guard.guard.spec.ts`).",
11+
"description": "The name for the new route guard. This will be used to create the guard's class and spec files (e.g., `example-guard.ts` and `example-guard.spec.ts`).",
1212
"$default": {
1313
"$source": "argv",
1414
"index": 0

‎packages/schematics/angular/interceptor/schema.json‎

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -8,7 +8,7 @@
88
"properties": {
99
"name": {
1010
"type": "string",
11-
"description": "The name for the new interceptor. This will be used to create the interceptor's class and spec files (e.g., `my-interceptor.interceptor.ts` and `my-interceptor.interceptor.spec.ts`).",
11+
"description": "The name for the new interceptor. This will be used to create the interceptor's class and spec files (e.g., `example-interceptor.ts` and `example-interceptor.spec.ts`).",
1212
"$default": {
1313
"$source": "argv",
1414
"index": 0

‎packages/schematics/angular/interface/schema.json‎

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -8,7 +8,7 @@
88
"properties": {
99
"name": {
1010
"type": "string",
11-
"description": "The name for the new interface. This will be used to create the interface file (e.g., `my-interface.interface.ts`).",
11+
"description": "The name for the new interface. This will be used to create the interface file (e.g., `my-interface.ts`).",
1212
"$default": {
1313
"$source": "argv",
1414
"index": 0

‎packages/schematics/angular/pipe/schema.json‎

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -8,7 +8,7 @@
88
"properties": {
99
"name": {
1010
"type": "string",
11-
"description": "The name for the new pipe. This will be used to create the pipe's class and spec files (e.g., `my-pipe.pipe.ts` and `my-pipe.pipe.spec.ts`).",
11+
"description": "The name for the new pipe. This will be used to create the pipe's class and spec files (e.g., `example-pipe.ts` and `example-pipe.spec.ts`).",
1212
"$default": {
1313
"$source": "argv",
1414
"index": 0

‎packages/schematics/angular/resolver/schema.json‎

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -8,7 +8,7 @@
88
"properties": {
99
"name": {
1010
"type": "string",
11-
"description": "The name for the new resolver. This will be used to create the resolver's class and spec files (e.g., `my-resolver.resolver.ts` and `my-resolver.resolver.spec.ts`).",
11+
"description": "The name for the new resolver. This will be used to create the resolver's class and spec files (e.g., `example-resolver.ts` and `example-resolver.spec.ts`).",
1212
"$default": {
1313
"$source": "argv",
1414
"index": 0

‎packages/schematics/angular/service/schema.json‎

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -8,7 +8,7 @@
88
"properties": {
99
"name": {
1010
"type": "string",
11-
"description": "The name for the new service. This will be used to create the service's class and spec files (e.g., `my-service.service.ts` and `my-service.service.spec.ts`).",
11+
"description": "The name for the new service. This will be used to create the service's class and spec files (e.g., `my-service.ts` and `my-service.spec.ts`).",
1212
"$default": {
1313
"$source": "argv",
1414
"index": 0

0 commit comments

Comments
 (0)