mirror of
https://github.com/gohugoio/hugo.git
synced 2025-08-31 22:41:53 +02:00
Merge commit '5be51ac3db225d5df501ed1fa1499c41d97dbf65'
This commit is contained in:
@@ -3,16 +3,10 @@ title: RawContent
|
||||
description: Returns the raw content of the given page.
|
||||
categories: []
|
||||
keywords: []
|
||||
action:
|
||||
related:
|
||||
- methods/page/Content
|
||||
- methods/page/Summary
|
||||
- methods/page/ContentWithoutSummary
|
||||
- methods/page/Plain
|
||||
- methods/page/PlainWords
|
||||
- methods/page/RenderShortcodes
|
||||
returnType: string
|
||||
signatures: [PAGE.RawContent]
|
||||
params:
|
||||
functions_and_methods:
|
||||
returnType: string
|
||||
signatures: [PAGE.RawContent]
|
||||
---
|
||||
|
||||
The `RawContent` method on a `Page` object returns the raw content. The raw content does not include front matter.
|
||||
@@ -21,12 +15,9 @@ The `RawContent` method on a `Page` object returns the raw content. The raw cont
|
||||
{{ .RawContent }}
|
||||
```
|
||||
|
||||
This is useful when rendering a page in a plain text [output format].
|
||||
This is useful when rendering a page in a plain text [output format](g).
|
||||
|
||||
{{% note %}}
|
||||
[Shortcodes](g) within the content are not rendered. To get the raw content with shortcodes rendered, use the [`RenderShortcodes`] method on a `Page` object.
|
||||
> [!note]
|
||||
> [Shortcodes](g) within the content are not rendered. To get the raw content with shortcodes rendered, use the [`RenderShortcodes`] method on a `Page` object.
|
||||
|
||||
[`RenderShortcodes`]: /methods/page/rendershortcodes/
|
||||
{{% /note %}}
|
||||
|
||||
[output format]: /templates/output-formats/
|
||||
|
Reference in New Issue
Block a user