From 2bde2f8d7ed4e08e06d4db84d04f4367581cdd30 Mon Sep 17 00:00:00 2001 From: zhaozhiwen Date: Fri, 14 Feb 2020 18:05:52 +0800 Subject: [PATCH] =?UTF-8?q?chore(new-comp):=20=E7=BB=84=E4=BB=B6=E5=88=9D?= =?UTF-8?q?=E5=A7=8B=E5=8C=96=E8=84=9A=E6=9C=AC=E4=BC=98=E5=8C=96?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .eslintignore | 1 + doczrc.js | 2 +- template/index.mdx | 2 +- template/index.tsx | 2 +- 4 files changed, 4 insertions(+), 3 deletions(-) diff --git a/.eslintignore b/.eslintignore index 5d25bc9..998aad5 100644 --- a/.eslintignore +++ b/.eslintignore @@ -1,3 +1,4 @@ *.js doc-comps components/**/demo +template diff --git a/doczrc.js b/doczrc.js index 75ad539..e5e8e53 100644 --- a/doczrc.js +++ b/doczrc.js @@ -1,5 +1,5 @@ export default { - files: './components/**/*.{md,markdown,mdx}', // 识别的文件后缀 + src: 'components', dest: 'doc-site', // 打包出来的文件目录名 title: 'happy-ui', // 站点标题 typescript: true, // 组件源文件是通过typescript开发,需要打开此选项 diff --git a/template/index.mdx b/template/index.mdx index c8b04b7..659ddeb 100644 --- a/template/index.mdx +++ b/template/index.mdx @@ -1,7 +1,7 @@ {{line_for_keep_metadata}} name: {{compNameEN}} {{compNameZH}} route: /{{compNameEN}} -menu: {{compNameEN}} +menu: 组件 {{line_for_keep_metadata}} import CodeBox from '../../doc-comps/happy-box'; diff --git a/template/index.tsx b/template/index.tsx index 4973286..d326bb0 100644 --- a/template/index.tsx +++ b/template/index.tsx @@ -8,7 +8,7 @@ interface State {} class {{compNameEN}} extends Component { static propTypes = {}; - static defaultProps: Partial = {}; + static defaultProps = {}; constructor(props: Props) { super(props);