You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Opening a html file that contains embedded CSS in it throws the following error:
[ERROR][2024-10-23 01:56:57] ...lsp/handlers.lua:623 "Error while validating file:///home/user/code/test.html: Cannot read properties of null (reading 'validProperties')
TypeError: Cannot read properties of null (reading 'validProperties')
at LintConfigurationSettings.getSetting (/home/user/.local/share/nvim/mason/packages/html-lsp/node_modules/vscode-langservers-extracted/node_modules/vscode-css-languageservice/lib/umd/services/lintRules.js:78:29)
at new LintVisitor (/home/user/.local/share/nvim/mason/packages/html-lsp/node_modules/vscode-langservers-extracted/node_modules/vscode-css-languageservice/lib/umd/services/lint.js:53:41)
at LintVisitor.entries (/home/user/.local/share/nvim/mason/packages/html-lsp/node_modules/vscode-langservers-extracted/node_modules/vscode-css-languageservice/lib/umd/services/lint.js:41:29)
at CSSValidation.doValidation (/home/user/.local/share/nvim/mason/packages/html-lsp/node_modules/vscode-langservers-extracted/node_modules/vscode-css-languageservice/lib/umd/services/cssValidation.js:34:60)
at _callee$ (/home/user/.local/share/nvim/mason/packages/html-lsp/node_modules/vscode-langservers-extracted/lib/html-language-server/modes/cssMode.js:53:69)
at tryCatch (/home/user/.local/share/nvim/mason/packages/html-lsp/node_modules/vscode-langservers-extracted/node_modules/regenerator-runtime/runtime.js:64:40)
at Generator.invoke (/home/user/.local/share/nvim/mason/packages/html-lsp/node_modules/vscode-langservers-extracted/node_modules/regenerator-runtime/runtime.js:299:22)
at Generator.next (/home/user/.local/share/nvim/mason/packages/html-lsp/node_modules/vscode-langservers-extracted/node_modules/regenerator-runtime/runtime.js:124:21)
at asyncGeneratorStep (/home/user/.local/share/nvim/mason/packages/html-lsp/node_modules/vscode-langservers-extracted/lib/html-language-server/modes/cssMode.js:17:103)
at _next (/home/user/.local/share/nvim/mason/packages/html-lsp/node_modules/vscode-langservers-extracted/lib/html-language-server/modes/cssMode.js:19:194)"
justinmk
changed the title
Default html-lsp config causes errors when opening a html file with CSS <style> tag in it
html-lsp: "cannot read null 'validProperties'" when opening a html file with CSS <style> tag
Oct 23, 2024
Description
Opening a html file that contains embedded CSS in it throws the following error:
Putting this in the config fixes it:
The text was updated successfully, but these errors were encountered: