Visual Studio Code: Failed to apply ESLint fixes to the document

eslint, javascript, linter, visual-studio-code

Solution

For anyone who bumps into the same issue. To troubleshoot, try running `npx eslint path/to/your/file` to see the actual eslint output.

In my case it was missing Prettier plugin:

`Failed to load plugin 'prettier' declared in '.eslintrc.js » @react-native-community/eslint-config': Cannot find module 'eslint-plugin-prettier'`

Problem

I am using Visual Studio Code 1.6.1, with latest version of ESLint extension installed and enabled. I have ``` "eslint.options": { "rules": { ... } } ``` in my vs-code user settings. I was able to autofix my js files with the auto command "eslint.executeAutofix", but from maybe my last update of vs-code I am receiving the following error: ``` Failed to apply ESLint fixes to the document. Please consider opening an issue with steps to reproduce. ``` Can somebody please help me or point me in direction where I can fix this issue?

Original source