feat: update oxfmt and oxlint to detect vite plus#4395
feat: update oxfmt and oxlint to detect vite plus#4395V1OL3TF0X wants to merge 4 commits intoneovim:masterfrom
Conversation
forgot that vite config can be also a marker if it has vite-plus import, added
|
I don't have a sense for how common or urgent this is. Need to hear from other oxlint users. At some point I would expect users to just... use These js projects are out of control, there seems to be 17 different config files in every js workspace. I wonder how other editors deal with this. Related to that, there is a cost to having complex logic: |
Npmx says 136k downloads/week for vite-plus, 4m/week for oxlint / oxfmt. The main problem for me was this feature was not well documented, so I had to dig pretty deep to find out how it's done (came from an issue about supporting per-file formatting on vp and then 4 layers of linked issues). If you think it's not worth changing the config, I'd leave a comment at least to guide someone who wants to implement it. I imagine vite-plus getting more popular with time tho.
Kinda lol |
|
#4391 is what worries me. A comment in the docstring is a good start, giving your insight. I'm not opposed to this change but hoping to hear from other oxlint users. And your |
|
A bit of background: Oxlint and Oxfmt are being used in two typical scenarios:
So both cases are relevant |
And @TheAlexLichter @justinmk correct me if I'm wrong, but the settings here act like a rough heuristic - oxlint/oxfmt will detect their proper configs anyway, according to their internal logic (I know oxlint has some config inheritance for example) |
Since oxfmt and oxlint have the ability to use vite plus config (as mentioned here: voidzero-dev/vite-plus#629), it would be great to update lspconfig to reflect that (terribly sorry it took me 4 commits to format message correctly)