Ecosyste.ms: Awesome
An open API service indexing awesome lists of open source software.
https://github.com/truqu/elm-mustache
Mustache templates in Elm
https://github.com/truqu/elm-mustache
Last synced: 4 months ago
JSON representation
Mustache templates in Elm
- Host: GitHub
- URL: https://github.com/truqu/elm-mustache
- Owner: truqu
- License: mit
- Archived: true
- Created: 2016-05-12T08:17:23.000Z (over 8 years ago)
- Default Branch: master
- Last Pushed: 2018-03-03T21:19:05.000Z (over 6 years ago)
- Last Synced: 2024-07-20T23:47:33.200Z (4 months ago)
- Language: Elm
- Size: 6.84 KB
- Stars: 15
- Watchers: 13
- Forks: 6
- Open Issues: 2
-
Metadata Files:
- Readme: README.md
- License: LICENSE
Awesome Lists containing this project
README
# Elm-Mustache
An Elm library for mustache templates
## Usage
```elm
import Mustachetemplate : String
template =
"Hi, my name is {{ name }}.{{# show }} Show me!{{/ show }}"evaluatedTemplate : String
evaluatedTemplate =
Mustache.render
[ Mustache.Variable "name" "John"
, Mustache.Section "show" True
]
template-- evaluatedTemplate == "Hi, my name is John. Show me!"
```