rimu 0.0.1

A data structure template system.
Documentation

rimu

crates.io version download docs.rs docs ci status

Work in progress...

Rimu is a structured template system. Unlike other template systems, Rimu operates on data structures, not text.

We use a data structure as a template, then using another data structure as context, produce an output data structure.

Install

TODO

Usage

Interpolation

Template:

message: hello {{key}}

Context:

key: world

Output:

message: hello world

Expressions

To evaluate expressions, we use Rhai.

Operations

Eval

Template:

- a
- b
- type: ops.eval
  expr: a + b

Context:

a: 1
b: 2

Output:

- 1
- 2
- 3

Let

If

Match

Switch

Map

MapObject

Flatten

FlattenDeep

Merge

MergeDeep

Sort

Reverse

Inspiration