Merge pull request #23186 from pselle/pselle/docs-syntax-link

Docs around splat and for_each
This commit is contained in:
Pam Selle 2019-10-24 16:15:18 -04:00 committed by GitHub
commit 5b453f6ba9
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
1 changed files with 4 additions and 0 deletions

View File

@ -317,6 +317,10 @@ be accessed using a [`for` expression](#for-expressions).
* `[for value in aws_instance.example: value.id]` returns a list of all of the ids
of each of the instances.
Note that unlike `count`, splat expressions are _not_ directly applicable to resources managed with `for_each`, as splat expressions are for lists only. You may apply a splat expression to values in a map like so:
* `values(aws_instance.example)[*].id`
### Local Named Values
Within the bodies of certain expressions, or in some other specific contexts,