I’m passing a glossary (for glossarium) to a template (via the parameter glossary
). The glossary is basically an array of arrays. If I pass it verbatim as in the following example, it works fine:
glossary: (
(
key: "Vulnerability",
description: "A Vulnerability is a flaw in a computer system that weakens the overall security of the system.",
),
(
key: "Patch",
description: "A patch is data that is intended to be used to modify an existing software resource such as a program or a file, often to fix bugs and security vulnerabilities.",
),
)
But as glossaries may become large, I would like to put it in a separate file. If I try to include
that file as follows, things don’t work any more (i.e. Typst doesn’t recognize the file content as an array of arrays):
glossary: include "myglossary.typ"
myglossary.typ
contains:
(
(
key: "Vulnerability",
description: "A Vulnerability is a flaw in a computer system that weakens the overall security of the system.",
),
(
key: "Patch",
description: "A patch is data that is intended to be used to modify an existing software resource such as a program or a file, often to fix bugs and security vulnerabilities.",
),
)
I assumed include
would just replace the file content 1:1. But obviously it doesn’t . So, how can I achieve this?