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
The "expression" on the RHS after the = is part of the existing grammars and we happen to treat standalone expressions, such as
42"foobar"
data.aws_instance.foo.tags["noot"]
The decision to treat standalone expressions as valid was mostly pragmatic, where it was easier to do it than not to, due to the way TextMate grammars and nesting inside works.
To date however, this was a rather "hidden feature".
Potential
There are context in which this can be genuinely useful. For example:
rendering full object structures in highlighted hover data (markdown), e.g. { foo = string, bar = set(number) }
History
The main context in which we expect HCL/Terraform grammars to be used is to highlight whole HCL "bodies". For example
The "expression" on the RHS after the
=
is part of the existing grammars and we happen to treat standalone expressions, such asThe decision to treat standalone expressions as valid was mostly pragmatic, where it was easier to do it than not to, due to the way TextMate grammars and nesting inside works.
To date however, this was a rather "hidden feature".
Potential
There are context in which this can be genuinely useful. For example:
{ foo = string, bar = set(number) }
...
inattr = "${...}"
- see Support Color Syntax Highlighting for Templates (tmpl, etc) vscode-terraform#496 / meta: Support for Terraform files other than .tf vscode-terraform#636Proposal
The text was updated successfully, but these errors were encountered: