summaryrefslogtreecommitdiff
path: root/examples/formatting.md
diff options
context:
space:
mode:
Diffstat (limited to 'examples/formatting.md')
-rw-r--r--examples/formatting.md48
1 files changed, 48 insertions, 0 deletions
diff --git a/examples/formatting.md b/examples/formatting.md
new file mode 100644
index 0000000..b56f85d
--- /dev/null
+++ b/examples/formatting.md
@@ -0,0 +1,48 @@
1Messages in `snac` allow a special subset of Markdown, that includes *emphasized*, **strong**, `monospaced`, ~~strikethrough~~ and __underlined__ styles by surrounding text with one asterisk, two asterisks, backquotes, two tildes and two underlines, respectively.
2
3Line breaks are respected and output as you write them.
4
5
6Prepending a greater-than symbol in a line makes it a quote:
7
8> This is quoted text
9>
10> All angle-prepended lines are grouped in the same blockquote
11
12It also allows preformatted text using three backquotes in a single line:
13
14```
15 /* this is preformatted text */
16
17 struct node {
18 struct node *prev;
19 struct node *next;
20 };
21
22```
23
24- One level bullet lists
25- are also supported,
26- by starting a line with a hyphen or asterisk followed by a space.
27
28URLs like https://en.wikipedia.org/wiki/Main_Page are made clickable, https://comam.es/what-is-snac.
29
30Links can also be written in [standard Markdown style](https://comam.es/what-is-snac).
31
32Some emojis: X-D <3 :beer: :shrug: :shrug2:
33
34Image URLs written in standard Markdown style for images ![susie, snac's girl](https://comam.es/snac-doc/susie64.png) are converted to ActivityPub attachments.
35
36Three minus symbols in a line make a separator:
37
38---
39
40Headings can be defined using one, two, or three hash symbols in the beginning of a line, followed by a blank:
41
42# header level 1
43## header level 2
44### header level 3
45
46But please take note that every ActivityPub implementation out there have its own rules for filtering out these formatting styles, so you can only guess what other people will really see.
47
48These acrobatics are better documented in the `snac(5)` man page.