Table of Content
- Vscode - {:.} ruler - {:.} wrap attribute
- Vetur in vs code - {:.} html prettier - {:.} wrap attribute
Vscode
ruler
"editor.rulers": [160],
wrap attribute
// Wrap attributes.
// - auto: Wrap attributes only when line length is exceeded.
// - force: Wrap each attribute except first.
// - force-aligned: Wrap each attribute except first and keep aligned.
// - force-expand-multiline: Wrap each attribute.
// - aligned-multiple: Wrap when line length is exceeded, align attributes vertically.
"html.format.wrapAttributes": "auto"
Vetur in vs code
html prettier
// Default formatter for <template> region
// - none: disable formatting
// - prettyhtml: prettyhtml
// - js-beautify-html: html formatter of js-beautify
"vetur.format.defaultFormatter.html": "prettyhtml",
wrap attribute
// Options for all default formatters
"vetur.format.defaultFormatterOptions": {
"js-beautify-html": {
"wrap_attributes": "force-expand-multiline"
},
"prettyhtml": {
"printWidth": 100,
"singleQuote": false,
"wrapAttributes": false,
"sortAttributes": false
}
},
Today I Learned