Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

feat: dumi 1.x -> 2.x #340

Merged
merged 2 commits into from
Jan 18, 2023
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Jump to
Jump to file
Failed to load files.
Diff view
Diff view
14 changes: 14 additions & 0 deletions .dumirc.ts
Original file line number Diff line number Diff line change
@@ -0,0 +1,14 @@
import { defineConfig } from 'dumi';
import path from 'path';

export default defineConfig({
alias: {
'rc-dialog$': path.resolve('src'),
'rc-dialog/es': path.resolve('src'),
},
favicons: ['https://avatars0.githubusercontent.com/u/9441414?s=200&v=4'],
themeConfig: {
name: 'Dialog',
logo: 'https://avatars0.githubusercontent.com/u/9441414?s=200&v=4',
},
});;
5 changes: 5 additions & 0 deletions .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -41,3 +41,8 @@ package-lock.json
.umi-production
.umi-test
.env.local


# dumi
.dumi/tmp
.dumi/tmp-production
21 changes: 0 additions & 21 deletions .umirc.ts

This file was deleted.

9 changes: 7 additions & 2 deletions docs/demo/ant-design.md
Original file line number Diff line number Diff line change
@@ -1,3 +1,8 @@
## ant-design
---
title: ant-design
nav:
title: Demo
path: /demo
---

<code src="../examples/ant-design.tsx">
<code src="../examples/ant-design.tsx"></code>
9 changes: 7 additions & 2 deletions docs/demo/bootstrap.md
Original file line number Diff line number Diff line change
@@ -1,3 +1,8 @@
## bootstrap
---
title: bootstrap
nav:
title: Demo
path: /demo
---

<code src="../examples/bootstrap.tsx">
<code src="../examples/bootstrap.tsx"></code>
9 changes: 7 additions & 2 deletions docs/demo/draggable.md
Original file line number Diff line number Diff line change
@@ -1,3 +1,8 @@
## draggable
---
title: draggable
nav:
title: Demo
path: /demo
---

<code src="../examples/draggable.tsx">
<code src="../examples/draggable.tsx"></code>
9 changes: 7 additions & 2 deletions docs/demo/multiple-Portal.md
Original file line number Diff line number Diff line change
@@ -1,3 +1,8 @@
## multiple-Portal
---
title: multiple-Portal
nav:
title: Demo
path: /demo
---

<code src="../examples/multiple-Portal.tsx">
<code src="../examples/multiple-Portal.tsx"></code>
9 changes: 7 additions & 2 deletions docs/demo/pure.md
Original file line number Diff line number Diff line change
@@ -1,3 +1,8 @@
## pure-debug
---
title: pure-debug
nav:
title: Demo
path: /demo
---

<code src="../examples/pure.tsx">
<code src="../examples/pure.tsx"></code>
4 changes: 3 additions & 1 deletion docs/index.md
Original file line number Diff line number Diff line change
@@ -1,5 +1,7 @@
---
title: rc-dialog
hero:
title: rc-dialog
description: React Dialog Component
---

<embed src="../README.md"></embed>
2 changes: 1 addition & 1 deletion now.json
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@
{
"src": "package.json",
"use": "@now/static-build",
"config": { "distDir": ".doc" }
"config": { "distDir": "dist" }
}
],
"routes": [
Expand Down
2 changes: 1 addition & 1 deletion package.json
Original file line number Diff line number Diff line change
Expand Up @@ -64,7 +64,7 @@
"bluebird": "~3.7.2",
"bootstrap": "^4.3.1",
"cross-env": "^7.0.0",
"dumi": "^1.1.0",
"dumi": "^2.1.3",
"enzyme": "^3.1.1",
"enzyme-adapter-react-16": "^1.0.1",
"enzyme-to-json": "^3.1.2",
Expand Down
5 changes: 3 additions & 2 deletions tsconfig.json
Original file line number Diff line number Diff line change
Expand Up @@ -9,8 +9,9 @@
"esModuleInterop": true,
"paths": {
"@/*": ["src/*"],
"@@/*": ["src/.umi/*"],
"@@/*": [".dumi/tmp/*"],
"rc-dialog": ["src/index.ts"]
}
}
},
"include": [".dumi/**/*", ".dumirc.ts", "./src/**/*.ts", "./src/**/*.tsx", "./docs/**/*.tsx", "./tests/**/*.tsx"]
}