Content and data

Load Markdown, JSON, YAML and XML into typed C# data, then shape it with processors, references and groups.

csharp
[DataSource("Posts", "./*.md", OrderBy = "Date desc, Title")]
public sealed record BlogPost(string Slug, string Title, DateOnly Date, string RawMarkdown);

You declare a record. Bevel reads your files during dotnet build and gives your pages typed data. Read these pages top to bottom.

  • Datasets

    Declare a record, point it at files, pick an order.

  • Markdown

    Bind front matter and the raw body.

  • JSON, YAML, XML

    The same record, three more formats.

  • Nested folders

    Read Markdown from folders below a root.

  • Required values and Unique

    Catch missing values and duplicate slugs.

  • References

    Link an item to an item in another dataset.

  • Groups

    Tags, categories and archives without code.

  • Processors

    Compute values and check content at build time.

  • Drafts

    Remove items from the data.

  • Build environment

    Which environment build-time code runs in.

  • Custom formats

    Read TOML, CSV or any text format with a small reader.

  • Loaders

    Load data that does not come from a file.