I want to build a section of use-cases
, with content that is composed of multiple content part, each with their own html layout, and with i18n.
The directory would look like this
/content
/use-case
/scenario1
- index.en.md
- index.de.md
- context.en.md
- context.de.md
/scenario2
…
/customer
…
/customer5
- index.md
- testimonial.en.md
- testimonial.de.md
/layouts
/use-case
- baseof.html
- single.html
With layouts/use-case/single.html that looks more or less like this
{{ define "main" }}
<main aria-role="main">
<article>
<header class="homepage-header">
<h1>{{.Title}}</h1>
</header>
<div class="use-case-content">
{{.Content}}
</div>
<div><!-- Content of "context.**.md" --></div>
<div><!-- Content of "testimonial.**.md" --></div>
</article>
</main>
{{ end }}
The scenario1 page should include scenario1/context.XX.md and customer5/testimonial.XX.md, with XX being the language code.
testimonial.**.md files look like
----
title: User Name
picture: "user.jpeg
company: Some,Inc
---
This is a **made-up** testimonial text.
and context.**.md files look like
----
title: Some context
---
You check those flags:
1. First one
2. Second one
3. Third one
I’m not quite sure about the way to go, could you please point me in the right direction about how to:
- insert context/testimonial files
- handle cross-references (customer5/testimonial.XX.md being used in scenario1)
Thank you