module

Hecr::LSP::Analyzer

Template diagnostics without a build: parses .hecr documents whole and every HECR heredoc inside .cr documents. When known_components is given, unknown <.component> usages produce warnings.

Constants

BUILTIN_COMPONENTS = ["content", "link", "dynamic_tag", "intersperse"]

Instance methods

diagnostics(path : String, text : String, known_components : Set(String) | Nil = nil) : Array(Diagnostic)
Source
strip_directive(source : String) : String

embed_templates contracts are not part of the body grammar — blank them (preserving positions), as the processor does.

Source