Moon Healing Reformation!!!
(I know it would be refactoration, but that sounds much worse)
This commit is contained in:
+82
-2
@@ -1,6 +1,5 @@
|
||||
! TypoML
|
||||
|
||||
|
||||
!! Installation
|
||||
|
||||
TypoML requires the Odin compiler. Build from source:
|
||||
@@ -19,6 +18,8 @@ TypoML reads from stdin and outputs HTML to stdout:
|
||||
cat input.tlm | ./TypoML > output.html
|
||||
```
|
||||
|
||||
---
|
||||
|
||||
!! Syntax
|
||||
|
||||
!!! Text Formatting
|
||||
@@ -31,6 +32,8 @@ cat input.tlm | ./TypoML > output.html
|
||||
`_` - H_2_O_4_U - Subscript
|
||||
`^` - Δ = b^2^ - 4ac - Superscript
|
||||
|
||||
---
|
||||
|
||||
!!! Headings
|
||||
|
||||
\! Heading 1
|
||||
@@ -38,6 +41,14 @@ cat input.tlm | ./TypoML > output.html
|
||||
\!!! Heading 3
|
||||
(And so on)
|
||||
|
||||
Result:
|
||||
|
||||
! Heading 1
|
||||
!! Heading 2
|
||||
!!! Heading 3
|
||||
|
||||
---
|
||||
|
||||
!!! Links
|
||||
|
||||
\#[Link text](url) - Standard link
|
||||
@@ -45,6 +56,15 @@ cat input.tlm | ./TypoML > output.html
|
||||
\#[url] - Auto-link (no alt text)
|
||||
[Link text](\#heading) - Header link (anchor) (can also be done like an auto-link, then the text is auto-generated from the heading)
|
||||
|
||||
Result:
|
||||
|
||||
#[Link text](https://example.com) - Standard link
|
||||
#(https://example.com)[Link text] - Can go either way
|
||||
#[https://example.com] - Auto-link (no alt text)
|
||||
[Link text](#headings) - Header link (anchor)
|
||||
|
||||
---
|
||||
|
||||
!!! Alignment
|
||||
|
||||
Placed at the end of start of a line
|
||||
@@ -53,6 +73,14 @@ Placed at the end of start of a line
|
||||
\<< - Left aligned
|
||||
\^^ - Center aligned
|
||||
|
||||
Result:
|
||||
|
||||
This text is right aligned >>
|
||||
This text is left aligned <<
|
||||
This text is center aligned ^^
|
||||
|
||||
---
|
||||
|
||||
!!! Embedded Content
|
||||
|
||||
\$[url] - Auto-detect type
|
||||
@@ -68,6 +96,13 @@ Types:
|
||||
- `iframe`, `frame`, `f`
|
||||
- `script`, `s`, `javascript`, `js`
|
||||
|
||||
Result:
|
||||
|
||||
$[https://upload.wikimedia.org/wikipedia/commons/b/b2/Voynich_manuscript_recipe_example_107r_crop.jpg|img]
|
||||
$[staircase.mp3]
|
||||
|
||||
---
|
||||
|
||||
!!! Lists
|
||||
|
||||
- Item 1
|
||||
@@ -80,6 +115,8 @@ Unordered lists use - or . as markers.
|
||||
|
||||
Ordered lists use numbers followed by periods.
|
||||
|
||||
---
|
||||
|
||||
!!! Code Blocks
|
||||
|
||||
```language
|
||||
@@ -88,6 +125,8 @@ code here
|
||||
|
||||
Inline code uses backticks: `code`
|
||||
|
||||
---
|
||||
|
||||
!!! Tables
|
||||
|
||||
| Header 1 | Header 2 | Header 3 |
|
||||
@@ -97,11 +136,20 @@ Inline code uses backticks: `code`
|
||||
Do not need a header to work, just the first separator row (`|---|---|---|`)
|
||||
Can be aligned using the alignment markers
|
||||
|
||||
---
|
||||
|
||||
!!! Blockquotes
|
||||
|
||||
\> This is a blockquote
|
||||
\> Multiple lines are supported
|
||||
|
||||
Result:
|
||||
|
||||
> This is a blockquote
|
||||
> Multiple lines are supported
|
||||
|
||||
---
|
||||
|
||||
!!! Footnotes
|
||||
|
||||
[\&footnote] - Footnote reference
|
||||
@@ -109,23 +157,55 @@ Can be aligned using the alignment markers
|
||||
|
||||
Can be numbers or names
|
||||
|
||||
Result:
|
||||
|
||||
Here is a footnote reference [&demo]
|
||||
|
||||
[&&demo] And here is its definition
|
||||
|
||||
---
|
||||
|
||||
!!! Variables
|
||||
|
||||
\$(name=value) - Define a variable
|
||||
\$(name) - Use a variable
|
||||
|
||||
Result:
|
||||
|
||||
$(greeting=Hello, world!)
|
||||
|
||||
The value of `greeting` is: $(greeting)
|
||||
|
||||
Variables can be accessed in JavaScript using `tlm.<name>` (without the `<>`)
|
||||
|
||||
---
|
||||
|
||||
!!! Script Blocks
|
||||
|
||||
\$[script]
|
||||
JavaScript code here
|
||||
\$[/script]
|
||||
|
||||
Result:
|
||||
|
||||
$[script]
|
||||
console.log("Hello from TypoML!");
|
||||
$[/script]
|
||||
|
||||
(Open your browser's console to see the output)
|
||||
|
||||
---
|
||||
|
||||
!!! Escaping
|
||||
|
||||
Standard escaping using a backslash (`\`)
|
||||
|
||||
!!! Horizontal Rules
|
||||
|
||||
\--\-, \__\_, or \==\=
|
||||
\---, \___, or \===
|
||||
|
||||
Three or more, have to be on their own line
|
||||
|
||||
Result:
|
||||
|
||||
---
|
||||
|
||||
Reference in New Issue
Block a user