You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
- [ x ] bug report -> please search issues before submitting
- [ ] feature request
Repro steps.
ng g m product-admin --routing
will produce
product-admin.module.ts
product-admin-routing.module.ts
Current Problem
Angular cli creates a module with product-admin.module and a module with product-admin-routing.module. This looks odd because it creates product-admin.component, product-admin.service, and so on. Perhaps it looks not only odd but is even wrong, because the complete angular world names with schema my-very-awesome-feature.[technical].ts like product-admin.state.ts, product-admin.actions.ts, product-admin.models.ts. Thats why product-admin.routing.ts should the correct way.
I know the routing module is a module - but it is only used for routing so it is not a classic "module". Thats why we need not name it "module".
I guess the naming comes from an early routing tutorial on angular.io. They named it hero-routing.module.ts there. That was just a quick example, how we could do it. Nevertheless most of the world outside named their routing module just feature.routing.ts. Some tools do it also. E.g. vscode-material-icons mark files with *.routing.ts as an angular routing file.
Desired functionality.
ng g m product-admin --routing
will produce
product-admin.module.ts
product-admin.routing.ts
The text was updated successfully, but these errors were encountered:
filipesilva
added
P5
The team acknowledges the request but does not plan to address it, it remains open for discussion
feature
Issue that requests a new feature
labels
Oct 25, 2017
Is there any workaround for this. Can not imagine that noone cares. The default in almost all projects is feature.routing.ts. Do all of them rename it by hand?
Bug Report or Feature Request (mark with an
x
)Repro steps.
ng g m product-admin --routing
will produce
product-admin.module.ts
product-admin-routing.module.ts
Current Problem
Angular cli creates a module with product-admin.module and a module with product-admin-routing.module. This looks odd because it creates product-admin.component, product-admin.service, and so on. Perhaps it looks not only odd but is even wrong, because the complete angular world names with schema my-very-awesome-feature.[technical].ts like product-admin.state.ts, product-admin.actions.ts, product-admin.models.ts. Thats why product-admin.routing.ts should the correct way.
I know the routing module is a module - but it is only used for routing so it is not a classic "module". Thats why we need not name it "module".
I guess the naming comes from an early routing tutorial on angular.io. They named it hero-routing.module.ts there. That was just a quick example, how we could do it. Nevertheless most of the world outside named their routing module just feature.routing.ts. Some tools do it also. E.g. vscode-material-icons mark files with *.routing.ts as an angular routing file.
Desired functionality.
ng g m product-admin --routing
will produce
product-admin.module.ts
product-admin.routing.ts
The text was updated successfully, but these errors were encountered: