eslint-plugin-jsonc
eslint-plugin-jsonc copied to clipboard
Autofix for jsonc/sort-keys doesn't fix in 1 iteration
I have very large translation files that should be alphabetized according to the jsonc/sort-keys
rule, but they autofix doesn't work in 1 iteration.
For a particularly large JSON file, it takes hitting save many times before the file is finally in the order it needs to be in.
Here's a minimal-ish sample:
{
"i::b::c": "",
"i::a::l": "",
"i::d::h": "",
"i::d::l": "",
"i::ap::mwd": "",
"i::b::cc": "",
"a::c::h::c": "",
"a::c::h::e": "",
"i::b::caj": "",
"i::b::cac": "",
"i::ap::av::l": "",
"i::ap::mw::la": "",
"a::c::pc::u": "",
"a::c::pe::u": "",
"a::c::vfi::u": ""
}
For the above file to be alphabetized, I have to hit save (which runs autofix) twice.
https://github.com/user-attachments/assets/14a69ac1-28e2-45a2-864e-8cb251de7034