Filament.SigilF (filament v0.2.1)

Copy Markdown

Implements the ~F sigil for compiling HEEx-style templates into VNode IR.

Templates use @foo to reference lexically-scoped variables (not an assigns map). The template is compiled using a custom EEx engine that transforms @foo to bare variable references.

Summary

Functions

Compiles a HEEx-style template string into a compiled expression.

Functions

sigil_F(arg, modifiers)

(macro)

Compiles a HEEx-style template string into a compiled expression.

Examples

iex> name = "World"
iex> ~F"<div>Hello {name}!</div>"
"Hello World!"