Questions tagged [prettier-vscode]
121 questions
0
votes
0 answers
Getting error on prettier settings not matching on docs when I put in PR
I added to markdown documents to an existing project and I get error on prettier settings not matching the projects. enter image description here.
I have my settings for prettier on vs code like this enter image description here
I read through this…

Paulieb
- 1
- 1
0
votes
1 answer
error msg setting editor preferences, format on save, format on paste for Prettier - unable to write into user settings. How do I correct this, pls?
Installed Prettier. Want to set preferences to format on paste and save but getting error message - unable to write into user settings. Please open the user settings to correct errors/warnings in it and try again.
To format prettier I went into the…

VEA
- 1
0
votes
0 answers
Problem with the ESlint + prettier configuration
I've been stuck for a few days on a VueMastery tutorial on the "Vue CLI". The tutorial is called "Real World Vue" for those who knows. Two problems occurred to me when I watched the third tutorial. I took the ESlint + Prettier configuration and the…

RENAUD
- 1
0
votes
1 answer
Which source code formatter is being used in react-admin?
I cloned the source code of react-admin from https://github.com/marmelab/react-admin.
When I tried formatting the source code by VS Code (Windows) with "Prettier - Code formatter" or "TypeScript and Javascript Language Features", the source code is…

Jacob Phan
- 732
- 2
- 6
- 20
0
votes
1 answer
Prettier CLI and VS Code Extension formatting anonymous function differently
I'm trying to format all TS files in my repo using Prettier CLI, but I'm running into an issue.
Prettier CLI and Prettier VS Code extension are formatting anonymous functions differently.
When I format the TS files using the CLI: npx prettier…

Ryan
- 550
- 4
- 9
0
votes
0 answers
Prettier auto messed up the HTML banner on save
When I formatted my code with Prettier, via Prettier's extension for VS Code, it changed my comment/banner in such a way that now it isn't aligned.
Is there a way to configure prettier so it won't change the alignment as seen in the image…

code-8
- 54,650
- 106
- 352
- 604
0
votes
0 answers
How to setup .prettierrc with the same default format document config of Visual Studio Code (VSCode)
in my case I need the config Prettier looks like when I do default "Format document" in VSCode. But I can't find the configuration.
Thanks for helping

dev Ina
- 3
- 3
0
votes
1 answer
Prettier adds multiple empty lines after JavaScript blocks wrongely
My prettier is adding extra empty lines after blocks in JavaScript. It is OK after first save and empty line is just one, but after second save it add another line, and after third save it add one more. It not adds more with further saves.
Example:
…

Saeed Sepehr
- 93
- 1
- 7
0
votes
1 answer
Conflict when i save my file(EsLint + Prittier formater)
I have that arrow function
I have this error in my file. To fix this error, I can return it like this => {return ...}, or just put parentheses around what is inside the arrow function
When I do that the error disappears, but if I save the file it…

Giuseppe Fantoni
- 183
- 4
- 11
0
votes
1 answer
Prettier not formatting HTML in Visual Studio Code
All I want to do is for Prettier to work on Visual Studio Code whenever I'm working on my HTML files, but nothing seems to work.
I made my default formatter Prettier.
I enabled Format on Save, Paste, and Type.
Whenever I use HTML files, I see that…

lollipop087542
- 1
- 1
0
votes
1 answer
what should I do when format tsconfig.json without change spaces and commas?
I want to format tsconfig.json without change spaces and commas.
this tsc --init config
enter image description here
after format,spaces and commas change.
what should I do?
enter image description here

微风笑雨
- 1
0
votes
1 answer
How can we tell Prettier to ignore a specific JSON file?
I am using VS Code and would like to exclude a specific json file data.json from being formatted by Prettier on save. Say it's in the root, then I create a file .prettierignore and add a line data.json (according to the docs).
This works fine with…

Script Raccoon
- 261
- 2
- 14
0
votes
0 answers
Eslint - Leave Extraneous Parentheses
I'm using VS Code to write Angular apps in TypeScript. I have the Prettier and ESLint extensions installed and I want to configure ESLint to not remove unnecessary parentheses. ESLint has a "no-extra-parens" and I'd like to turn it off.
As a…

Jeffery Pyle
- 1
- 1
- 4
0
votes
1 answer
Auto Formatting adding text on VS Code
Working on a shared project and my coworker created a new branch with an updated npm package (@mui/material from @material-ui/core). When I pull his branch and run npm install everything installs and works correctly. But now if I make a change to a…

adam.tarr57
- 1
- 1
0
votes
1 answer
How can we set our vs code prettier on save format to the rules mentioned in .prettierrc
1st image : before save
2nd image : after saving formats to some default config by vs code
I am getting lint errors after saving the file(right side). Even after fixing it and then saving again goes back to the error state.
How do we make our vs…

Hussam Khatib
- 600
- 6
- 17