Skip to content

HTML#

Server#

For more information about the LSP server, check html.

Installation#

This Server supports automatic install. Install this language server with M-xlsp-install-serverREThtml-lsRET.

npm install -g vscode-html-languageserver-bin

Debugger: Not available#

Available configurations#

lsp-html-experimental-custom-data#

Default: nil

A list of JSON file paths that define custom tags, properties and other HTML syntax constructs. Only workspace folder setting will be read.


lsp-html-format-enable#

Default: t

Enable/disable default HTML formatter.


lsp-html-format-wrap-line-length#

Default: 120

Maximum amount of characters per line (0 = disable).


lsp-html-format-unformatted#

Default: wbr


lsp-html-format-content-unformatted#

Default: pre,code,textarea


lsp-html-format-indent-inner-html#

Default: nil


lsp-html-format-preserve-new-lines#

Default: t

Controls whether existing line breaks before elements should be preserved. Only works before elements, not inside tags or for text.


lsp-html-format-max-preserve-new-lines#

Default: nil


lsp-html-format-indent-handlebars#

Default: nil


lsp-html-format-end-with-newline#

Default: nil

End with a newline.


lsp-html-format-extra-liners#

Default: head, body, /html


lsp-html-format-wrap-attributes#

Default: auto

Wrap attributes.


lsp-html-suggest-html5#

Default: t

Controls whether the built-in HTML language support suggests HTML5 tags, properties and values.


lsp-html-validate-scripts#

Default: t

Controls whether the built-in HTML language support validates embedded scripts.


lsp-html-validate-styles#

Default: t

Controls whether the built-in HTML language support validates embedded styles.


lsp-html-auto-closing-tags#

Default: t

Enable/disable autoclosing of HTML tags.


lsp-html-trace-server#

Default: off

Traces the communication between VS Code and the HTML language server.


lsp-html-server-command-args#

Default: (--stdio)

Command to start html-languageserver.



Last update: April 15, 2021