MoonBit already has a strong language core and toolchain, but reusable template
rendering is still a missing piece in the ecosystem. Many practical tools need
to turn structured data into text output:
project scaffolding
configuration generation
static content rendering
email and notification templates
code generation helpers
This project focuses on a small, stable, reusable core instead of building a
feature-heavy template language.
This repository is in active bootstrap. Early commits focus on project
structure, design notes, and minimal MoonBit code skeletons that will be
expanded into a reusable library.
关于
A Mustache template engine implementation for MoonBit
Moon Mustache
Moon Mustache is a Mustache template engine implementation for MoonBit.
Moon Mustache 是一个面向 MoonBit 生态的 Mustache 模板引擎实现,目标是提供轻量、稳定、可复用的模板渲染基础能力,服务于脚手架生成、配置文件渲染、静态内容拼装、邮件模板和消息正文生成等场景。
Why this project
MoonBit already has a strong language core and toolchain, but reusable template rendering is still a missing piece in the ecosystem. Many practical tools need to turn structured data into text output:
This project focuses on a small, stable, reusable core instead of building a feature-heavy template language.
目前要解决的问题
MoonBit 生态当前已经具备不错的语言设计和统一工具链,但在很多项目会反复遇到的通用基础能力上仍然有补齐空间。模板渲染正是其中很典型的一类需求:
Moon Mustache 计划优先把这些场景需要的核心能力做扎实,而不是扩展成一个功能过重、边界不清的大模板语言。
Stage-one scope
The first milestone focuses on:
当前阶段交付
当前仓库处于第一阶段启动状态,已经完成:
后续会继续补齐扫描器、解析器、上下文查找、Partial 支持、文件接口和规范兼容测试。
Planned features
Planned public API
The project is currently planned around a small public surface:
parse_templaterender_stringrender_fileThe intent is to keep the API small and predictable so it can be embedded into other MoonBit tools without dragging in unnecessary complexity.
Repository layout
src/: library source filescli/: command-line entry pointexamples/: usage snippets and sample flowsdocs/: proposal, design, and roadmap notes.github/workflows/: CI configurationDevelopment plan
Near-term work is planned in roughly this order:
CI status
The repository includes a bootstrap CI workflow intended to run basic checks and tests once the MoonBit toolchain is available in the CI environment.
Reference projects
Repository status
This repository is in active bootstrap. Early commits focus on project structure, design notes, and minimal MoonBit code skeletons that will be expanded into a reusable library.