今天看到一个老哥的博客可以把一段文字折叠起来。于是问了一下,原来实用的是Markdownsummary语法。

语法:

1
2
3
4
5
6
7
<details>
<summary>Title</summary>

content!!!
- **<summary>标签与正文间一定要空一行!!!**
- 实在是太6了,在内容里面还可以嵌入MD语法。
</details>

例子:

collapsible markdown?

点击查看FiberRoot
1
2
3
4
5
6
7
export type Fiber = {|

// 指的是functionComponent 还是 classComponent等等, lazyComponent
tag: WorkTag,

// Unique identifier of this child.
key: null | string,