how to use prettier code example
Example 1: run prettier
npx prettier --write path/to/my/file.html
Example 2: prettier whole project
prettier --write "**/*.js"
Example 3: prittier download ubuntu
npm install --save-dev --save-exact prettier
Example 4: prettier on save vscode
{
"folders": [],
"settings": {},
"editor.formatOnSave": true,
}
Example 5: prettier on save vscode
// Set the default"editor.formatOnSave": false,// Enable per-language"[javascript]": { "editor.formatOnSave": true}
Example 6: enable prettier vscode
ext install esbenp.prettier-vscode