summaryrefslogtreecommitdiffstats
path: root/docs/content/en/functions/resources/FromString.md
diff options
context:
space:
mode:
Diffstat (limited to 'docs/content/en/functions/resources/FromString.md')
-rw-r--r--docs/content/en/functions/resources/FromString.md10
1 files changed, 8 insertions, 2 deletions
diff --git a/docs/content/en/functions/resources/FromString.md b/docs/content/en/functions/resources/FromString.md
index 6c22b5310..75f48ad9c 100644
--- a/docs/content/en/functions/resources/FromString.md
+++ b/docs/content/en/functions/resources/FromString.md
@@ -1,6 +1,6 @@
---
title: resources.FromString
-description: Creates a resource from a string.
+description: Returns a resource created from a string.
categories: []
keywords: []
action:
@@ -11,7 +11,13 @@ action:
signatures: [resources.FromString TARGETPATH STRING]
---
-Hugo publishes the resource to the target path when you call its`.Publish`, `.Permalink`, or `.RelPermalink` method. The resource is cached, using the target path as the cache key.
+The `resources.FromString` function returns a resource created from a string, caching the result using the target path as its cache key.
+
+Hugo publishes the resource to the target path when you call its [`Publish`], [`Permalink`], or [`RelPermalink`] methods.
+
+[`publish`]: /methods/resource/publish
+[`permalink`]: /methods/resource/permalink
+[`relpermalink`]: /methods/resource/relpermalink
Let's say you need to publish a file named "site.json" in the root of your public directory, containing the build date, the Hugo version used to build the site, and the date that the content was last modified. For example: