niamtokik 1acf814967 update
2023-12-14 10:00:51 +00:00
2023-12-07 18:30:10 +00:00
2023-12-07 16:27:31 +00:00
2023-12-14 10:00:51 +00:00
2023-12-07 16:43:09 +00:00
2023-11-30 17:49:34 +00:00
2023-11-30 17:49:34 +00:00
2023-12-14 10:00:51 +00:00
2023-11-30 17:49:34 +00:00
2023-11-30 20:03:45 +00:00

erml

An html library for Erlang, and an sandbox for Erlang, Cowboy, Htmx Spectre, Mnesia (ECHSM).

Build

rebar3 compile

Usage

{html, [
  {head, [
    {title, <<"my website">>},
    {meta, #{ name => "twitter:card", content => "summary"}}
  ]},
  {body, [
    
  ]}
]}.

Documentation

Stability Elements Notes
Standard Elements
s {Tag, Content} Create an html element without attributes
s {Tag, Attributes, Content} Create an html element with attributes
s {{empty, Tag}, Attributes} Create an empty element
s {content, Content} Add raw content
Variables
s {Variable} Insert a variable
Inclusion
u {include, Path} include an erml file
u {include, Path, Opts} include an erml file with custom options
u {include_raw, Path} include a raw file
u {include_raw, Path, Opts} include a raw file with custom options
u {template, Type, Data, Param} insert a template
u {template_file, Type, Filename, Param} insert a template file
Functions/Modules call
s {apply, Module, Function, Arguments} call a module/function
s {apply, Function, Arguments} call a function
s {apply, Function} call a function
Process Call
u {call, Pid, Message} call a gen_server process
u {call, Pid, Message, Timeout} call a gen_server process
u {gen_server, call, Pid, Message} call a gen_server process
u {gen_server, call, Pid, Message, Timeout} call a gen_server process
u {gen_statem, call, Pid, Message} call a gen_statem process
u {gen_statem, call, Pid, Message, Timeout} call a gen_statem process

Where u: unstable; s: stable

{Tag, Content}

Description
html library for Erlang, and an sandbox for Erlang, Cowboy, Htmx Spectre, Mnesia (ECHSM).
Readme 232 KiB
Languages
Erlang 99.9%