From 5665444349b1c5834e57257e1783a6a47958d573 Mon Sep 17 00:00:00 2001 From: afc163 Date: Mon, 13 Mar 2017 15:49:15 +0800 Subject: [PATCH] update readme --- README-zh_CN.md | 16 ++++++++++------ README.md | 17 ++++++++--------- docs/react/introduce.en-US.md | 26 +++++++++++++------------- docs/react/introduce.zh-CN.md | 26 +++++++++++++------------- 4 files changed, 44 insertions(+), 41 deletions(-) diff --git a/README-zh_CN.md b/README-zh_CN.md index 44143a4b1d..0487ff69d1 100644 --- a/README-zh_CN.md +++ b/README-zh_CN.md @@ -26,6 +26,16 @@ - 使用 TypeScript 构建,提供完整的类型定义文件。 - 基于 npm + webpack + [dva](https://github.com/dvajs/dva) 的企业级开发框架。 +## 支持环境 + +* 现代浏览器和 IE9 及以上。 +* 支持服务端渲染。 +* [Electron](http://electron.atom.io/) + +## 参与共建 [![PRs Welcome](https://img.shields.io/badge/PRs-welcome-brightgreen.svg?style=flat-square)](http://makeapullrequest.com) + +`antd` 是一个开源项目,我们欢迎社区参与共建。如果你对此项目感兴趣,有 [很多方式](https://opensource.guide/how-to-contribute/) 进行参与。你可以 watch 这个仓库,加入 [issue 中的讨论](https://github.com/ant-design/ant-design/issues?q=is%3Aopen+is%3Aissue+label%3ADiscussion),以及尝试实现一些 [已接受的特性](https://github.com/ant-design/ant-design/issues?q=is%3Aopen+is%3Aissue+label%3A%22PR+welcome%22)。我们会给予有活跃贡献的社区成员 [collaborator 权限](https://github.com/ant-design/ant-design/issues/3222)。 + ## 安装 ```bash @@ -47,12 +57,6 @@ import 'antd/dist/antd.css'; // or 'antd/dist/antd.less' 按需加载可通过此写法 `import DatePicker from 'antd/lib/date-picker'` 或使用插件 [babel-plugin-import](https://github.com/ant-design/babel-plugin-import)。 -## 浏览器支持 - -现代浏览器和 IE9 及以上。 - -> [IE8 issues](https://github.com/xcatliu/react-ie8) - ## TypeScript ```js diff --git a/README.md b/README.md index 34ad202c44..4010fb93f2 100644 --- a/README.md +++ b/README.md @@ -26,9 +26,15 @@ An enterprise-class UI design language and React-based implementation. - Written in TypeScript with complete define types. - A npm + webpack + [dva](https://github.com/dvajs/dva) front-end development workflow. +## Environment Support + +* Browser: Modern browsers and Internet Explorer 9+ +* Server-side Rendering +* [Electron](http://electron.atom.io/) + ## Let's build a better antd together [![PRs Welcome](https://img.shields.io/badge/PRs-welcome-brightgreen.svg?style=flat-square)](http://makeapullrequest.com) -`antd` is an open source project, improvements are welcomed. If you are interested in contributing to `antd`, you can watch this repository, join in [discussion](https://github.com/ant-design/ant-design/issues?q=is%3Aopen+is%3Aissue+label%3ADiscussion), or try to implement some [features which have been accepted](https://github.com/ant-design/ant-design/issues?q=is%3Aopen+is%3Aissue+label%3A%22PR+welcome%22). Actually, there are [many ways](https://opensource.guide/how-to-contribute/) to contribute. +`antd` is an open source project, improvements are welcomed. If you are interested in contributing to `antd`, you can watch this repository, join in [discussion](https://github.com/ant-design/ant-design/issues?q=is%3Aopen+is%3Aissue+label%3ADiscussion), or try to implement some [features which have been accepted](https://github.com/ant-design/ant-design/issues?q=is%3Aopen+is%3Aissue+label%3A%22PR+welcome%22). Actually, there are [many ways](https://opensource.guide/how-to-contribute/) to contribute. And we are always happy to [offer collaborator permission](https://github.com/ant-design/ant-design/issues/3222) for some active contributors. ## Install @@ -77,14 +83,7 @@ import 'antd/dist/antd.css'; // or 'antd/dist/antd.less' // import 'antd/lib/date-picker/style'; // that will import less ``` -## Environment Support - -* Browser: Modern browsers and Internet Explorer 9+. -> [IE8 issues](https://github.com/xcatliu/react-ie8) -* Server-side Rendering -* [Electron](http://electron.atom.io/) - -## TypeScript +### TypeScript ```js // tsconfig.json diff --git a/docs/react/introduce.en-US.md b/docs/react/introduce.en-US.md index d3bed634e5..20a23ce7df 100644 --- a/docs/react/introduce.en-US.md +++ b/docs/react/introduce.en-US.md @@ -110,22 +110,22 @@ import 'antd/dist/antd.css'; // or 'antd/dist/antd.less' // import 'antd/lib/date-picker/style'; // that will import less ``` - ## TypeScript - - ```js - // tsconfig.json - { - "compilerOptions": { - "moduleResolution": "node", - "jsx": "preserve", - "allowSyntheticDefaultImports": true - } +### TypeScript + +```js +// tsconfig.json +{ + "compilerOptions": { + "moduleResolution": "node", + "jsx": "preserve", + "allowSyntheticDefaultImports": true } - ``` +} +``` - > Note: set `allowSyntheticDefaultImports` to prevent `error TS1192: Module 'react' has no default export`. +> Note: set `allowSyntheticDefaultImports` to prevent `error TS1192: Module 'react' has no default export`. - > Note: Don't use @types/antd, antd provide a built-in ts definition already. +> Note: Don't use @types/antd, antd provide a built-in ts definition already. ## Links diff --git a/docs/react/introduce.zh-CN.md b/docs/react/introduce.zh-CN.md index 1ad76380be..37b2b01c1a 100644 --- a/docs/react/introduce.zh-CN.md +++ b/docs/react/introduce.zh-CN.md @@ -113,22 +113,22 @@ import 'antd/dist/antd.css'; // or 'antd/dist/antd.less' // import 'antd/lib/date-picker/style'; // 加载 LESS ``` - ## TypeScript - - ```js - // tsconfig.json - { - "compilerOptions": { - "moduleResolution": "node", - "jsx": "preserve", - "allowSyntheticDefaultImports": true - } +### TypeScript + +```js +// tsconfig.json +{ + "compilerOptions": { + "moduleResolution": "node", + "jsx": "preserve", + "allowSyntheticDefaultImports": true } - ``` +} +``` - > 注意:设置 `allowSyntheticDefaultImports` 避免 `error TS1192: Module 'react' has no default export` 的错误。 +> 注意:设置 `allowSyntheticDefaultImports` 避免 `error TS1192: Module 'react' has no default export` 的错误。 - > 注意: 不要使用 @types/antd, antd 已经自带了 TypeScript 定义。 +> 注意: 不要使用 @types/antd, antd 已经自带了 TypeScript 定义。 ## 链接