This would add an optional feature that allows maud to embed a runtime parser/interpreter that can read its own macro block from Rust source code. This runtime templating is limited in scope, meaning that changes to data, bindings, etc will require a recompile, but other changes could be done by interpreting the macro block at runtime (which IMO covers a lot of iteration time). This is definitely a bigger task with multiple steps, but I think it can be a really useful feature.
This is something Dioxus has implemented as a CLI tool, and I made a proof-of-concept implementation html_hotreload! (renamed to html! in the video) macro that uses maud's parser to generate a runtime instead that also parses itself at runtime (inception...).
Is this something you'd be interested in including with maud as an optional feature, or is it out of scope for maud? I think it could be it's own crate with a small refactor to expose maud's proc-macro/parser internals.
Love the library, it's really nice!
This would add an optional feature that allows maud to embed a runtime parser/interpreter that can read its own macro block from Rust source code. This runtime templating is limited in scope, meaning that changes to data, bindings, etc will require a recompile, but other changes could be done by interpreting the macro block at runtime (which IMO covers a lot of iteration time). This is definitely a bigger task with multiple steps, but I think it can be a really useful feature.
This is something Dioxus has implemented as a CLI tool, and I made a proof-of-concept implementation
html_hotreload!
(renamed tohtml!
in the video) macro that uses maud's parser to generate a runtime instead that also parses itself at runtime (inception...).https://github.com/lambda-fairy/maud/assets/7478134/274f2fcd-99e2-4cc2-899d-925d07f08263
Is this something you'd be interested in including with maud as an optional feature, or is it out of scope for maud? I think it could be it's own crate with a small refactor to expose maud's proc-macro/parser internals.
Either way, thanks for the useful library!