We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Allow specifying language to use in front matter like so:
---toml answer = 42 ---
11ty uses gray-matter for parsing front matter, which supports using any language as front matter, but doesn't support +++ notation for TOML.
+++
In order to hack in support for +++, you have to make +++ a delimiter, and make TOML the default engine. Here's an example with 11ty config:
const toml = require("@iarna/toml"); module.exports = function(cfg) { cfg.setFrontMatterParsingOptions({ engines: { toml: toml.parse.bind(toml) }, language: "toml", delimiters: "+++", }); };
The text was updated successfully, but these errors were encountered:
No branches or pull requests
Feature
Allow specifying language to use in front matter like so:
---toml answer = 42 ---
Reason
11ty uses gray-matter for parsing front matter, which supports using any language as front matter, but doesn't support
+++
notation for TOML.+++
support workaround for gray-matterIn order to hack in support for
+++
, you have to make+++
a delimiter, and make TOML the default engine. Here's an example with 11ty config:The text was updated successfully, but these errors were encountered: