-
Notifications
You must be signed in to change notification settings - Fork 65
Open
Description
Given:
import {
transformDeclarations,
transformECMAScriptModule,
Transformer,
TransformerFactory,
transformES5,
transformES2015,
transformES2016,
transformES2017,
transformES2018,
transformES2019,
transformES2020,
} from "./_namespaces/ts";
eslint-plugin-simple-import-sort
sorts these like the above, which is to say naturally. TS also does this (with some configuration). dprint formats these in string order only:
import {
transformDeclarations,
transformECMAScriptModule,
Transformer,
TransformerFactory,
transformES2015,
transformES2016,
transformES2017,
transformES2018,
transformES2019,
transformES2020,
transformES5,
} from "./_namespaces/ts";
It'd be great if natural sorting were an option. I'm not sure how feasible that is cross-platform, but both eslint-plugin-simple-import-sort and TS use Intl.Collator
to do this, so maybe it's standardish.
Metadata
Metadata
Assignees
Labels
No labels