Skip to content
New issue

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

fix: shortcodes documentation #127

Merged
merged 1 commit into from
Sep 8, 2022
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 0 additions & 2 deletions docs/content/configuration.md
Original file line number Diff line number Diff line change
Expand Up @@ -18,7 +18,6 @@ base_url = "http://localhost:3000"
about = "This site is generated with Bartholomew, the Spin micro-CMS. And this message is in site.toml."
theme = "fermyon"
index_site_pages = ["main"]
enable_shortcodes = false

[extra]
copyright = "The Site Authors"
Expand All @@ -36,7 +35,6 @@ It has a few pre-defined fields:
- about: a brief description of the site
- theme: the name of the theme for the website from the `/themes/` folder
- index_site_pages: A list of templates that require `site.pages` to be populated.
- enable_shortcodes: Allows the addition of shortcodes in the markdown content using rhai scripts. Defaults to false.

You can define your own fields in the `[extra]` section. Anything in `[extra]` is not
used by the system itself. But it's a useful way to pass information from one central
Expand Down
2 changes: 2 additions & 0 deletions docs/content/markdown.md
Original file line number Diff line number Diff line change
Expand Up @@ -37,6 +37,7 @@ description = "This article is really interesting and full of useful material."
date = "2021-12-23T15:05:19Z"
template = "post"
tags = ["news", "article"]
enable_shortcodes = false

[extra]
author = "Matt Butcher"
Expand Down Expand Up @@ -80,6 +81,7 @@ The following fields are defined for Bartholomew:
- NOTE: `content_type` has no impact on the formatting. That is, Markdown will still be rendered to HTML.
- `status`: (EXPERT) Status code and message for HTTP. E.g. "302 Found"
- `redirect`: (EXPERT) Send a redirect to the given fully qualified URL. The default redirect type is `301 Moved Permanently`. Use `status` to set another redirect type. When this is set, no body is sent to the client.
- `enable_shortcodes`: Allows the addition of shortcodes in the markdown content using rhai scripts. Defaults to false.
- `[extra]`: The section marker indicates that all content after it is user-defined.
- Fields under extra MUST be in the form `name = "value"`. All values must be strings.
- once the `[extra]` section is declared, you cannot declare top-level fields anymore.
Expand Down