Comments (3)
This is a problem for me as well. I have autoFixOnSave enabled since I usually do want to use it. But some projects do not have an eslint configuration because they don't use eslint at all. In these cases not only do I get a loud error message but the file cannot be saved.
I understand that this feature does require an eslint configuration to work, since that's what eslint itself requires. But it should probably not prevent writing files altogether
Error detected while processing BufWritePre Autocommands for "*"..function coc#rpc#request[4]..<SNR>45_request[34]..BufWritePre Autocommands for "*"..function coc#rpc#request[4]..<SNR>45_request:
line 31:
E605: Exception not caught: Error on request: Vim(return):Error invoking 'doAutocmd' on channel 3 (coc):^@Request textDocument/codeAction failed with message: No ESLint configuration found in /home/mrmelve/.dotfiles/vim/.vim.
Maybe there is a way to catch and show the warning message but still allow the autocmd to finish successfully?
from coc-eslint.
Same issue
from coc-eslint.
To avoid this error, I think coc-eslint needs default eslint config that can be used when there is no config files in project.
I changed my formatter to prettier to temporarily fix this issue for my own.
I added _ to my old config property "eslint.autoFixOnSave"
and add "coc.preferences.formatOnSaveFileTypes": ["*"]
{
"_eslint.autoFixOnSave": true,
...
"coc.preferences.formatOnSaveFileTypes": ["*"],
...
}
from coc-eslint.
Related Issues (20)
- Coc-eslint doesn't work with eslint@8 HOT 10
- undeprecate `eslint.enable`
- coc-eslint does not detect eslintrc unless it is placed in the root folder HOT 4
- Connection to server got closed. Server will not be restarted. HOT 1
- Usage with XO
- Is there any configuration for easily opening a recommendation link? HOT 1
- The "initializing eslint" notification never disappears HOT 2
- [bug] Diagnostic level hard-coded to Unnecessary/Warning/1 for no-unused-vars rule HOT 3
- UnhandledRejection opening markdown files HOT 22
- Stuck as "Initializing eslint" popup
- ESLint 8 flat config support HOT 3
- Parsing error: ESLint was configured to run on .... However that TSConfig does not include this file HOT 1
- how does eslint work
- shoudFix parameter was false HOT 4
- Need some clarification
- Coc-eslint not working with yarn Plug'n'Play HOT 2
- Setting `useFlatConfig` to true breaks ESLint integration for projects that use the older config style HOT 1
- is coc-eslint still maintained? HOT 5
- are there plans to support eslint 9? HOT 5
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from coc-eslint.