Skip to content

Register a function in Tera #2493

Open
Open
@MaoHolden

Description

@MaoHolden

Register a Tera function in order to execute complex logic like calculating read time.

Summary

Zola uses the Tera engine, I would like to calculate the read time of my markdown posts. One way I thing it could be done is by adding a Rust function in the Tera engine using tera.register_function but I don't see how this can be done in the documentation.

Proposed solution

Either specify that its not possible yet or document how.

Greetings

Thank you for the great framework 🤩.

Metadata

Metadata

Assignees

No one assigned

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions