I am currently trying to standardize my line endings to LF, whilst working in Windows. I have eslint and prettier set up in my project. These extensions are enforcing the consistent line endings in all files. However, when I save a particular file, that file gets changed to CRLF for some reason. Here is a gif demonstrating the issue:
I have added the option "files.eol": "\n"
to my settings.json, as some other posts suggested. But it still doesn't work. Here is my entire settings.json if it helps.
{
"editor.suggestSelection": "first",
"workbench.colorTheme": "Dracula",
"workbench.iconTheme": "material-icon-theme",
"editor.fontFamily": "Fira Code",
"editor.fontLigatures": true,
"editor.fontSize": 14,
"editor.rulers": [80, 120],
"editor.renderLineHighlight": "gutter",
"editor.tabSize": 2,
"terminal.integrated.fontSize": 14,
"emmet.includeLanguages": {
"javascript": "javascriptreact"
},
"emmet.syntaxProfiles": {
"javascript": "jsx"
},
"editor.parameterHints.enabled": true,
"breadcrumbs.enabled": true,
"javascript.suggest.autoImports": false,
"editor.codeActionsOnSave": {
"source.fixAll.eslint": true
},
"files.associations": {
".sequelizerc": "javascript",
".stylelintrc": "json",
".prettierrc": "json",
"*.pl": "prolog"
},
"[dart]": {
"editor.formatOnSave": true,
"editor.formatOnType": true,
"editor.rulers": [
80
],
"editor.selectionHighlight": false,
"editor.suggest.snippetsPreventQuickSuggestions": false,
"editor.suggestSelection": "first",
"editor.tabCompletion": "onlySnippets",
"editor.wordBasedSuggestions": false
},
"dart.openDevTools": "flutter",
"window.zoomLevel": 1,
"files.eol": "\n"
}
Thank you in advance for any help provided. :)