Skip to content

Commit 1f72f19

Browse files
committed
Style Guide: Switch front matter to JSON
1 parent ec2923e commit 1f72f19

File tree

1 file changed

+11
-10
lines changed

1 file changed

+11
-10
lines changed

page/style-guide.md

Lines changed: 11 additions & 10 deletions
Original file line numberDiff line numberDiff line change
@@ -10,28 +10,29 @@ customFields:
1010

1111
## Formatting Conventions
1212

13-
Articles in the learn site are authored with [GitHub Flavored Markdown](http://github.github.com/github-flavored-markdown/), and the beginning of each article contains some [YAML](http://www.yaml.org/) "front matter" that contains metadata used when the article is published.
13+
Articles in the learn site are authored with [GitHub Flavored Markdown](http://github.github.com/github-flavored-markdown/), and the beginning of each article contains some JSON "front matter" that contains metadata used when the article is published.
1414

1515
### Article Header Metadata
1616

1717
Each article should have the following header (see below as some metatags are optional):
1818

1919
```
20-
---
21-
title: <article title>
22-
level: [beginner|intermediate|advance]
23-
source: <url of source of the material derived>
24-
attribution:
25-
- Ralph Whitbeck <ralph@email.com>
26-
- John Paul <john@email.com>
27-
---
20+
<script>{
21+
"title": <article title>,
22+
"level": [beginner|intermediate|advance],
23+
"source": <url of source of the material derived>,
24+
"attribution": [
25+
"Ralph Whitbeck <ralph@email.com>",
26+
"John Paul <john@email.com>"
27+
]
28+
}</script>
2829
```
2930

3031
The `source` and `attribution` properties are optional, and should be used primarily if you are importing an article from an outside source where it was published before being donated for inclusion in the learn site. You should **not** include these properties if you are adding a new article or editing an existing one, as your contribution will be acknowledged via the git commit logs.
3132

3233
### Code Blocks
3334

34-
Code blocks should be set off with triple backticks and should **not** be indented. (That is to say, the site prefers the use of "fenced blocks"notation supported by [gfm](http://github.github.com/github-flavored-markdown/).)
35+
Code blocks should be set off with triple backticks and should **not** be indented. (That is to say, the site prefers the use of "fenced blocks" notation supported by [gfm](http://github.github.com/github-flavored-markdown/).)
3536

3637
## Writing Style
3738

0 commit comments

Comments
 (0)