Skip to content

Commit 9a59fe9

Browse files
committed
🆕 feature: AntdTypescript.md added;
🎨 chore: README.md/SUMMARY.md/md-config.js updated;
1 parent 0700644 commit 9a59fe9

File tree

4 files changed

+38
-1
lines changed

4 files changed

+38
-1
lines changed

README.md

+2-1
Original file line numberDiff line numberDiff line change
@@ -88,6 +88,7 @@
8888

8989
React 相关知识总结
9090

91+
- [Antd typescript](/full-stack/react/AntdTypescript.md): <sub><sup>(2023年9月20日)</sup></sub>
9192
- [React: 总结整理](/full-stack/react/React.md): <sub><sup>(2023年8月7日)</sup></sub>
9293
- [React Hook - 速览](/full-stack/react/ReactHook.md): <sub><sup>(2021年8月10日)</sup></sub>
9394
- [React-生命周期方法转 Hooks-1](/full-stack/react/ReactLifeCycleToHooks1.md): <sub><sup>(2021年3月29日)</sup></sub>
@@ -120,4 +121,4 @@ Office 工具技巧
120121
- [Excel 常用操作](/office/Excel.md): <sub><sup>(2021年2月24日)</sup></sub>
121122
- [Word: 文档操作精选技巧](/office/Word.md): <sub><sup>(2020年8月31日)</sup></sub>
122123

123-
最后更新于2023年8月7日
124+
最后更新于2023年9月20日

SUMMARY.md

+1
Original file line numberDiff line numberDiff line change
@@ -91,6 +91,7 @@
9191

9292
React 相关知识总结
9393

94+
- [Antd typescript](/full-stack/react/AntdTypescript.md)
9495
- [React: 总结整理](/full-stack/react/React.md)
9596
- [React Hook - 速览](/full-stack/react/ReactHook.md)
9697
- [React-生命周期方法转 Hooks-1](/full-stack/react/ReactLifeCycleToHooks1.md)

assets/scripts/md-config.js

+5
Original file line numberDiff line numberDiff line change
@@ -255,6 +255,11 @@ module.exports = {
255255
"date": "2021年8月5日",
256256
"path": "full-stack/react/useEffect.md",
257257
"title": "useEffect"
258+
},
259+
"AntdTypescript.md": {
260+
"date": "2023年9月20日",
261+
"path": "full-stack/react/AntdTypescript.md",
262+
"title": "Antd typescript"
258263
}
259264
},
260265
"project": {

full-stack/react/AntdTypescript.md

+30
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,30 @@
1+
# Antd typescript
2+
3+
## Demos
4+
5+
```tsx
6+
import type { InputRef } from 'antd';
7+
import type { FieldData } from 'rc-field-form/lib/interface';
8+
9+
const Index: React.FC = () => {
10+
11+
const inputRef = useRef<InputRef>(null);
12+
13+
const handleFieldsChange = (changedFields: FieldData[], allFields: FieldData[]) => {
14+
// ......
15+
}
16+
17+
return (
18+
<Form
19+
onFieldsChange={handleFieldsChange}
20+
form={form}
21+
>
22+
</Form>
23+
)
24+
}
25+
26+
```
27+
28+
```tsx
29+
30+

0 commit comments

Comments
 (0)