[sort-ngmodule-metadata-arrays] suggestion - sort by package name #772
Labels
blocked:issue
This issue requires another issue on @angular-eslint to be resolved first
enhancement
New feature or request
package: eslint-plugin
Angular-specific TypeScript rules
Hi! I use prettier with the prettier-plugin-organize-imports plugin. It sorts the imports alphabetically.
Let's say I have a module:
Notice that the modules are sorted alphabetically and items in the
imports
array have the same order. It looks nice and consistent. 3rd party modules go first, then modules from other directories, then modules from the same folder. But I have to maintain the order manually and sadly my colleagues might not care to do that.Now, if I enable the
sort-ngmodule-metadata-arrays
to force the order of items, the code will look like this:Now the order of items in the
imports
array does not match the order of imports. Now 3rd party and local modules are mixed. In my opinion, such order is not good for visual scanning, despite being in the alphabetical order.Please consider having an option to sort items in the
imports
array by package name, if that's possible of course. Thanks!The text was updated successfully, but these errors were encountered: