Skip to content
This repository has been archived by the owner on Feb 13, 2020. It is now read-only.

truqu/elm-mustache

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

8 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

Elm-Mustache

An Elm library for mustache templates

Usage

import Mustache


template : 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!"