Commit 040282d
committed
fix(@schematics/angular): generate interceptors with a dash type separator
To align with the updated style guide, Angular v20 will generate interceptors
with file extension `interceptor` type prefixed with a `-` separator instead of
a `.` by default. Projects will automatically use this naming convention.
Projects can however opt-out by setting the `typeSeparator` option to `.`
for the interceptor schematic. This can be done as a default in the `angular.json`
or directly on the commandline via `--type-separator=.` when executing `ng generate`.
As an example, `example.interceptor.ts` will now be named `example-interceptor.ts`.
The TypeScript declaration will continue to contain `Interceptor` such as with `ExampleInterceptor`.1 parent ea1143d commit 040282d
File tree
7 files changed
+38
-10
lines changed- packages/schematics/angular/interceptor
- class-files
- functional-files
- tests/legacy-cli/e2e/tests/generate/interceptor
7 files changed
+38
-10
lines changed| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
1 | 1 | | |
2 | 2 | | |
3 | | - | |
| 3 | + | |
4 | 4 | | |
5 | 5 | | |
6 | 6 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
1 | 1 | | |
2 | 2 | | |
3 | 3 | | |
4 | | - | |
| 4 | + | |
5 | 5 | | |
6 | 6 | | |
7 | 7 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
46 | 46 | | |
47 | 47 | | |
48 | 48 | | |
| 49 | + | |
| 50 | + | |
| 51 | + | |
| 52 | + | |
| 53 | + | |
| 54 | + | |
| 55 | + | |
| 56 | + | |
| 57 | + | |
49 | 58 | | |
50 | 59 | | |
51 | 60 | | |
| 61 | + | |
| 62 | + | |
| 63 | + | |
| 64 | + | |
| 65 | + | |
| 66 | + | |
| 67 | + | |
| 68 | + | |
| 69 | + | |
| 70 | + | |
| 71 | + | |
| 72 | + | |
| 73 | + | |
52 | 74 | | |
53 | 75 | | |
54 | 76 | | |
| |||
57 | 79 | | |
58 | 80 | | |
59 | 81 | | |
60 | | - | |
61 | | - | |
| 82 | + | |
| 83 | + | |
62 | 84 | | |
63 | 85 | | |
64 | 86 | | |
| |||
67 | 89 | | |
68 | 90 | | |
69 | 91 | | |
70 | | - | |
| 92 | + | |
71 | 93 | | |
72 | 94 | | |
73 | 95 | | |
| |||
77 | 99 | | |
78 | 100 | | |
79 | 101 | | |
80 | | - | |
| 102 | + | |
81 | 103 | | |
82 | 104 | | |
83 | 105 | | |
| |||
90 | 112 | | |
91 | 113 | | |
92 | 114 | | |
93 | | - | |
| 115 | + | |
94 | 116 | | |
95 | 117 | | |
96 | 118 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
45 | 45 | | |
46 | 46 | | |
47 | 47 | | |
| 48 | + | |
| 49 | + | |
| 50 | + | |
| 51 | + | |
| 52 | + | |
| 53 | + | |
48 | 54 | | |
49 | 55 | | |
50 | 56 | | |
| |||
Lines changed: 3 additions & 3 deletions
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
7 | 7 | | |
8 | 8 | | |
9 | 9 | | |
10 | | - | |
| 10 | + | |
11 | 11 | | |
12 | | - | |
13 | | - | |
| 12 | + | |
| 13 | + | |
14 | 14 | | |
15 | 15 | | |
16 | 16 | | |
| |||
0 commit comments