My ESLint import/order
rule is behaving abnormally. It used to work fine before but I have recently run some package upgrades on my application and the alphabetize property is arranging my import statements in the wrong order.
This is my eslint config:
"import/order": ["error", {
"groups": ["builtin", "external", "internal"],
"alphabetize": {
"order": "asc",
"caseInsensitive": true
},
}],
These are the original import statements:
import { data } from "../../shared/myfile.tokens";
import { data } from "./../../shared/myfile.service";
These are what ESlint modified them to:
import { data } from "./../../shared/myfile.service";
import { data } from "../../shared/myfile.tokens";
But why is this happening? ESLint is supposed to arrange them in ascending order and “..” comes before “./” in the charset?
Any help would be greatly appreciated.