import-js/eslint-plugin-import
Auf GitHub ansehen[import/no-duplicates] Extra comma added when fixer is run
Open
#2.757 geöffnet am 9. Apr. 2023
bughelp wanted
Repository-Metriken
- Stars
- (4.946 Stars)
- PR-Merge-Metriken
- (Durchschn. Merge 138T 22h) (3 gemergte PRs in 30 T)
Beschreibung
Input:
import { Foo } from "someImport";
import {
BarLongNameToEnsureLineBreak,
BazManLongNameToEnsureLineBreak,
} from "someImport";
import { Qux } from "someImport";
const foo: Foo = "foo";
const bar: BarLongNameToEnsureLineBreak = "bar";
const baz: BazManLongNameToEnsureLineBreak = "baz";
const qux: Qux = "qux";
output:
import { Foo ,
BarLongNameToEnsureLineBreak,
BazManLongNameToEnsureLineBreak,
, Qux } from "someImport";
const foo: Foo = "foo";
const bar: BarLongNameToEnsureLineBreak = "bar";
const baz: BazManLongNameToEnsureLineBreak = "baz";
const qux: Qux = "qux";
Note the commas at the end of line 3 and start of line 4.
Possibly related to #2601, tho in that case it appears that the opposite problem is occurring: no comma when there should be