当前位置:网站首页>Markdown advanced syntax, marktext compatible

Markdown advanced syntax, marktext compatible

2022-06-22 02:42:00 The end of the world and you

1. Metadata

Front matter Allows you to insert metadata into your document . The preceding content block must be written on the first line , And then everything else , As shown in the following example .

YAML

YAML The front-end content block starts and ends --- Line identification .

---
title: YAML front matter example
key: value
---

Lorem ipsum dolor sit amet, graecis denique ei vel, at duo primis mandamus.

Display style :
 Insert picture description here

TOML

TOML The front-end content block starts and ends +++ Line identification .

+++
title = "YAML front matter example"
key = "value"
+++

Lorem ipsum dolor sit amet, graecis denique ei vel, at duo primis mandamus.

Display style :
 Insert picture description here

JSON

JSON The preceding content block is composed of the beginning and the end ;;; Line or {} identification .

{
    
"title": YAML front matter example
"key": {
    
  "subkey1": "value 1",
  "subkey2": "value 2"
}
}

Lorem ipsum dolor sit amet, graecis denique ei vel, at duo primis mandamus.

Display style :
 Insert picture description here


2. The mathematical formula

Inline mathematical formula

Put a line LaTeX Change to a dollar sign :$

For example, to show $\alpha \beta \gamma$ inline with other text, just wrap it in dollar signs.

Display style :
 Insert picture description here

Block mathematical formula

Two consecutive dollar signs are used to represent multiline mathematical formulas :$$

for example , This :

$$
R_x=\begin{
    pmatrix}
1 & 0 & 0 & 0\\
0 & cos(a) & -sin(a) & 0\\
0 & sin(a) & cos(a) & 0\\
0 & 0 & 0 & 1
\end{
    pmatrix}
$$

or

$$
m=\frac{
    b_y-a_y}{
    b_x-a_x}
$$

Display style :
 Insert picture description here


3. original HTML

Anything between <> Between looks like HTML The marked text will be parsed into the original HTML Mark and render as HTML Without escaping .

**Visit <a href="https://github.com">Jon Schlinkert's GitHub Profile</a>.**

Display style :
 Insert picture description here


4. Escape with backslash

whatever ASCII Punctuation characters can be escaped with a single backslash .

Example :

\*this is not italic*

Display style :
 Insert picture description here

原网站

版权声明
本文为[The end of the world and you]所创,转载请带上原文链接,感谢
https://yzsam.com/2022/172/202206211708461642.html