rcv
rcv copied to clipboard
IntelliJ / JSON whitespace formatting issue
Continuing our discussion in #232:
OK, yeah, I'm pretty confident that IntelliJ is the culprit for all this nonsense. I looked for a bit and couldn't figure out how to either a) tell it to ignore JSON entirely when it reformats, or b) make its rules identical to what DefaultPrettyPrinter is doing. For now, I'm just going to be careful not to let it touch JSON files. I'll open a separate issue for the more robust solution.
Turns out that IntelliJ has a whole section in the settings for JSON. See Editor > Code Style > JSON
. In it, there are options to choose if spaces are added before :, after :, or both, among other things. It seems like, if we all get on the same page here, it should work fine.
I haven't had any of the issues that Louis brought up, so I'm guessing he needs to match my settings, which are the standard GoogleStyle scheme that we all loaded up initially. In the "Spaces" tab, I only have "After comma" and "After ':'" checked, for example.