Skip to content

Add Wikimedia-style templates #44

@ozxybox

Description

@ozxybox

It would be fantastic if we could get Wikimedia-style templates.

We should be able to make a HTML template in the Wiki repo, store it under templates/ or something like that, and then refer to it from the markdown.

An example from Wikipedia would be their "under construction" banner to tell users that a page is a work in progress.
For us, we would put an HTML file with the banner into templates/UnderConstruction.html. Then from a markdown file, writing {{UnderConstruction}} should substitute the tag with the contents of the HTML file.

Reference pages
https://en.wikipedia.org/wiki/Help:Template
https://commons.wikimedia.org/wiki/Commons:Templates
https://gohugo.io/templates/introduction/

Note: should we reuse the existing template substitution syntax for this? https://github.com/StrataSource/strata-wiki/blob/5cda791c8446246a985567609256eba14235b482/src/exporter/template.ts#L49C1-L53C10

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions