eslint-config-angular-strict 22.1.4 → 22.1.5
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/naming-conventions.js +3 -4
- package/package.json +1 -1
package/naming-conventions.js
CHANGED
|
@@ -261,16 +261,15 @@ export const namingConventionOverrides = [
|
|
|
261
261
|
},
|
|
262
262
|
},
|
|
263
263
|
|
|
264
|
-
// routes.ts / *.routes.ts: only imports +
|
|
264
|
+
// routes.ts / *.routes.ts: only imports + const declarations allowed (routes + colocated resolvers/guards as local const)
|
|
265
265
|
{
|
|
266
266
|
files: ['**/routes.ts', '**/*.routes.ts'],
|
|
267
267
|
rules: {
|
|
268
268
|
'no-restricted-syntax': [
|
|
269
269
|
'error',
|
|
270
270
|
{
|
|
271
|
-
selector:
|
|
272
|
-
|
|
273
|
-
message: 'Only imports, export const and function declarations allowed in *.routes.ts',
|
|
271
|
+
selector: 'Program > :not(ImportDeclaration, VariableDeclaration[kind="const"], ExportNamedDeclaration:has(> VariableDeclaration[kind="const"]))',
|
|
272
|
+
message: 'Only imports and const declarations allowed in *.routes.ts',
|
|
274
273
|
},
|
|
275
274
|
],
|
|
276
275
|
},
|