Skip to content

Commit

Permalink
docs: Update Go expression syntax example
Browse files Browse the repository at this point in the history
  • Loading branch information
gamebox committed Dec 12, 2023
1 parent 5a65b4d commit 6126878
Showing 1 changed file with 4 additions and 4 deletions.
8 changes: 4 additions & 4 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -56,13 +56,13 @@ the rendered content.
```gwirl
<h1>@name</h1>
<h2>@pkg.SomeFunction(var1)</h2>
@GwirlRaw(userContent)
@!userContent
```

Use an arbitrary Go expression (simple expressions only) and that content will
be escaped appropriately and rendered as a string directly into the content
using the `Stringer` interface. Use the `@GwirlRaw` function to render content
as-is with no escaping.
be rendered as a string directly into the content using the `Stringer`
interface. Use the `@!` syntax to render content with escaping that is
appropriate to the content's filetype.

### Imports

Expand Down

0 comments on commit 6126878

Please sign in to comment.