Skip to content

Commit d164f7f

Browse files
authored
docs: use dumi2.x (#38)
* fix: fix type derivation error * chore: father@4 * chore: remove less deps * chore: 使用 rc 组织下的 father-plugin * chore: 使用 rc-test 增强 jest * chore: 移除多余配置 * chore(deps): add dumi@2 chore: 修复 dumi 配置文件错误问题 * docs: 迁移文档 * chore(pkg): update scripts * docs: update alias * style: format code
1 parent cc1a8e1 commit d164f7f

30 files changed

+162
-139
lines changed

.dumirc.ts

Lines changed: 17 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,17 @@
1+
// more config: https://d.umijs.org/config
2+
import { defineConfig } from 'dumi';
3+
import path from 'path';
4+
5+
export default defineConfig({
6+
alias: {
7+
'rc-motion$': path.resolve('src'),
8+
'rc-motion/es': path.resolve('src'),
9+
},
10+
favicons: ['https://avatars0.githubusercontent.com/u/9441414?s=200&v=4'],
11+
themeConfig: {
12+
name: 'Motion',
13+
logo: 'https://avatars0.githubusercontent.com/u/9441414?s=200&v=4',
14+
},
15+
outputPath: '.doc',
16+
exportStatic: {},
17+
});

.fatherrc.js

Lines changed: 0 additions & 9 deletions
This file was deleted.

.fatherrc.ts

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,5 @@
1+
import { defineConfig } from 'father';
2+
3+
export default defineConfig({
4+
plugins: ['@rc-component/father-plugin'],
5+
});

.gitignore

Lines changed: 6 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -28,4 +28,9 @@ es
2828
yarn.lock
2929
package-lock.json
3030
coverage/
31-
.doc
31+
.doc
32+
33+
# dumi
34+
.dumi/tmp
35+
.dumi/tmp-production
36+
.dumi/tmp-test

.npmignore

Lines changed: 0 additions & 29 deletions
This file was deleted.

.prettierignore

Lines changed: 0 additions & 12 deletions
This file was deleted.

README.md

Lines changed: 2 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -1,12 +1,6 @@
11
# rc-motion
22

3-
[![NPM version][npm-image]][npm-url]
4-
[![npm download][download-image]][download-url]
5-
[![build status][github-actions-image]][github-actions-url]
6-
[![Codecov][codecov-image]][codecov-url]
7-
[![Dependencies][david-image]](david-url)
8-
[![DevDependencies][david-dev-image]][david-dev-url]
9-
[![bundle size][bundlephobia-image]][bundlephobia-url]
3+
[![NPM version][npm-image]][npm-url] [![npm download][download-image]][download-url] [![build status][github-actions-image]][github-actions-url] [![Codecov][codecov-image]][codecov-url] [![Dependencies][david-image]](david-url) [![DevDependencies][david-dev-image]][david-dev-url] [![bundle size][bundlephobia-image]][bundlephobia-url]
104

115
[npm-image]: http://img.shields.io/npm/v/rc-motion.svg?style=flat-square
126
[npm-url]: http://npmjs.org/package/rc-motion
@@ -35,7 +29,7 @@ https://react-component.github.io/motion/
3529

3630
## Example
3731

38-
```tsx
32+
```js
3933
import CSSMotion from 'rc-motion';
4034

4135
export default ({ visible }) => (

docs/demo/basic.md

Lines changed: 8 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,8 @@
1+
---
2+
title: basic
3+
nav:
4+
title: Demo
5+
path: /demo
6+
---
7+
8+
<code src="../examples/basic.tsx"></code>

docs/demo/deadline.md

Lines changed: 8 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,8 @@
1+
---
2+
title: deadline
3+
nav:
4+
title: Demo
5+
path: /demo
6+
---
7+
8+
<code src="../examples/deadline.tsx"></code>

docs/demo/list.md

Lines changed: 8 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,8 @@
1+
---
2+
title: list
3+
nav:
4+
title: Demo
5+
path: /demo
6+
---
7+
8+
<code src="../examples/list.tsx"></code>

0 commit comments

Comments
 (0)