summaryrefslogtreecommitdiff
path: root/docs/src
diff options
context:
space:
mode:
authorMALO <57839069+MDLC01@users.noreply.github.com>2023-05-30 10:13:27 +0200
committerGitHub <noreply@github.com>2023-05-30 10:13:27 +0200
commit644bbf99145042266ea8cf2890cef5771bd04be4 (patch)
treeb19aaeb5d9ad95dee18bf182804ca93d6719f1fd /docs/src
parentb6b6666efdde33a3727955fb2254ba16a886e1d3 (diff)
Add `fields` method to content (#1340)
Diffstat (limited to 'docs/src')
-rw-r--r--docs/src/reference/types.md7
1 files changed, 7 insertions, 0 deletions
diff --git a/docs/src/reference/types.md b/docs/src/reference/types.md
index 13ca8720..715427f3 100644
--- a/docs/src/reference/types.md
+++ b/docs/src/reference/types.md
@@ -604,6 +604,13 @@ field does not exist or fails with an error if no default value was specified.
A default value to return if the field does not exist.
- returns: any
+### fields()
+Return the fields of this content.
+
+```example
+#repr(rect(width: 10cm, height: 10cm).fields())
+```
+
### location()
The location of the content. This is only available on content returned by
[query]($func/query), for other content it will fail with an error. The