mirror of
https://github.com/l0ng-ai/openidea.git
synced 2026-11-24 16:04:21 +00:00
Runs @tailwindcss/language-server next to the language's own servers for HTML, CSS, JS/JSX, TS/TSX, Vue, Svelte and Astro, only below a tailwind.config.* (v3) or a package.json listing tailwindcss in dependencies or devDependencies (v4), with one-click install like the ESLint and Angular servers. JSON root markers (package.json#…) now match a key with any non-null value, not only objects. Adds fixtures/tailwind-app and an ignored real-server test. Co-authored-by: wildcatDownstairs <26499420+wildcatDownstairs@users.noreply.github.com>
62 lines
2.5 KiB
TOML
62 lines
2.5 KiB
TOML
id = "html"
|
||
name = "HTML"
|
||
formatter = { tool = "prettier", parser = "html", range = false }
|
||
extensions = ["html", "htm", "xhtml", "shtml", "html.tmpl"]
|
||
first-line = "^\\s*<!(?i:doctype)\\s+html"
|
||
block-comment = ["<!--", "-->"]
|
||
indent = { tab-size = 2, insert-spaces = true }
|
||
ui-mode = "HTML"
|
||
tree-sitter = "html"
|
||
|
||
# Rainbow brackets › angle: editor syntax nodes of markup tags, whose `<` `>` pair up.
|
||
[rainbow-brackets]
|
||
tags = ["OpenTag", "CloseTag", "SelfClosingTag"]
|
||
|
||
# Angular projects: component templates, with bindings and interpolations
|
||
# highlighted as expressions.
|
||
[[framework-ui-modes]]
|
||
ui-mode = "Angular Template"
|
||
root-markers = ["angular.json", "node_modules/@angular/core"]
|
||
|
||
# Spring MVC projects: Thymeleaf templates, with `th:*` attribute values
|
||
# highlighted as Thymeleaf expressions.
|
||
[[framework-ui-modes]]
|
||
ui-mode = "Thymeleaf"
|
||
root-markers = ["src/main/resources/templates"]
|
||
|
||
# Angular projects only: component templates. First, so that hover, rename and
|
||
# document symbols of templates come from it rather than plain HTML.
|
||
[[language-servers]]
|
||
name = "angular-language-server"
|
||
command = "ngserver"
|
||
args = ["--stdio", "--includeCompletionsWithSnippetText", "--includeAutomaticOptionalChainCompletions"]
|
||
root-markers = ["angular.json", "node_modules/@angular/core"]
|
||
require-root-marker = true
|
||
install-hint = "npm i -g @angular/language-server"
|
||
|
||
[[language-servers]]
|
||
name = "vscode-html-language-server"
|
||
command = "vscode-html-language-server"
|
||
args = ["--stdio"]
|
||
initialization-options = { provideFormatter = true, embeddedLanguages = { css = true, javascript = true } }
|
||
install-hint = "npm i -g vscode-langservers-extracted"
|
||
|
||
# Tailwind CSS: class completion, hover and diagnostics, only in a project that uses Tailwind
|
||
# (`tailwind.config.*` or `tailwindcss` in package.json). After the language's own servers,
|
||
# which answer hover first.
|
||
[[language-servers]]
|
||
name = "tailwindcss-language-server"
|
||
command = "tailwindcss-language-server"
|
||
args = ["--stdio"]
|
||
root-markers = ["tailwind.config.*", "package.json#dependencies.tailwindcss", "package.json#devDependencies.tailwindcss"]
|
||
require-root-marker = true
|
||
install-hint = "npm i -g @tailwindcss/language-server"
|
||
|
||
# Scripts in a page run in the browser: breakpoints in them are hit by a JavaScript Debug configuration.
|
||
[debugger]
|
||
adapter = "js-debug"
|
||
command = "js-debug-adapter"
|
||
args = ["${port}", "127.0.0.1"]
|
||
transport = "tcp"
|
||
install-hint = "Install JavaScript Debugger (vscode-js-debug) in Settings › Languages & Frameworks › Language Servers"
|