flowpack / mustache
Mustache template Fusion object
Installs: 176
Dependents: 0
Suggesters: 0
Security: 0
Stars: 0
Watchers: 12
Forks: 0
Open Issues: 0
Type:neos-package
Requires
- mustache/mustache: ^2.0
- neos/flow: ^4.0|^5.0|^6.0
This package is auto-updated.
Last update: 2024-10-29 06:00:14 UTC
README
Opinionated Mustache templates.
TL;DR
composer require flowpack/mustache
- Inherit the Template object and set template variables as keys
prototype(Your.Site:Hello) < prototype(Flowpack.Mustache:Template) {
planet = 'Earth'
}
-
Place a Mustache template into
Packages/Sites/Your.Site/Resources/Private/Fusion/Hello/Hello.html
. E.g.Hello, {{planet}}
-
Alternatively you can use it as an Eel helper, e.g.
@process.params = ${Mustache.render('Hello, {{planet}}', {planet: 'Earth'})}
. Useful for replacing some placeholders in content.