-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
* improve docs * Add english version of docs
- Loading branch information
Showing
47 changed files
with
3,454 additions
and
247 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,83 +1,150 @@ | ||
module.exports = { | ||
title: 'UmiJS', | ||
description: '🌋 可插拔的企业级 react 应用框架。', | ||
// locales: { | ||
// '/': { | ||
// lang: 'en-US', | ||
// description: 'Blazing-fast next.js-like framework for React apps.', | ||
// }, | ||
// '/zh/': { | ||
// lang: 'zh-CN', | ||
// description: '极快的类 Next.js 的 React 应用框架。', | ||
// }, | ||
// }, | ||
locales: { | ||
'/': { | ||
lang: 'en-US', | ||
description: '🌋 Pluggable enterprise-level react application framework.', | ||
}, | ||
'/zh/': { | ||
lang: 'zh-CN', | ||
description: '🌋 可插拔的企业级 react 应用框架。', | ||
}, | ||
}, | ||
serviceWorker: {}, | ||
themeConfig: { | ||
repo: 'umijs/umi', | ||
lastUpdated: 'Last Updated', | ||
editLinks: true, | ||
editLinkText: '在 GitHub 上编辑此页', | ||
docsDir: 'docs', | ||
serviceWorker: { | ||
updatePopup: { | ||
message: 'New content is available.', | ||
buttonText: 'Refresh', | ||
}, | ||
}, | ||
nav: [ | ||
{ text: '指南', link: '/guide/' }, | ||
{ text: '配置', link: '/config/' }, | ||
{ text: 'API', link: '/api/' }, | ||
{ text: '插件', link: '/plugin/' }, | ||
{ text: 'V1 文档', link: 'https://v1.umijs.org/' }, | ||
{ text: '发布日志', link: 'https://github.com/umijs/umi/releases' }, | ||
], | ||
sidebar: { | ||
'/guide/': [ | ||
{ | ||
title: '指南', | ||
collapsable: false, | ||
children: [ | ||
'', | ||
'getting-started', | ||
'examples-and-boilerplates', | ||
'app-structure', | ||
'router', | ||
'navigate-between-pages', | ||
'config', | ||
'html-template', | ||
locales: { | ||
'/': { | ||
selectText: 'Languages', | ||
label: 'English', | ||
editLinkText: 'Edit this page on GitHub', | ||
nav: [ | ||
{ text: 'Guide', link: '/guide/' }, | ||
{ text: 'Config', link: '/config/' }, | ||
{ text: 'API', link: '/api/' }, | ||
{ text: 'Plugin', link: '/plugin/' }, | ||
{ text: 'V1 Docs', link: 'https://v1.umijs.org/' }, | ||
{ text: 'Changelog', link: 'https://github.com/umijs/umi/releases' }, | ||
], | ||
sidebar: { | ||
'/guide/': [ | ||
{ | ||
title: 'Guide', | ||
collapsable: false, | ||
children: [ | ||
'', | ||
'getting-started', | ||
'create-umi-app', | ||
'examples', | ||
'app-structure', | ||
'router', | ||
'navigate-between-pages', | ||
'config', | ||
'html-template', | ||
], | ||
}, | ||
{ | ||
title: 'Advanced', | ||
collapsable: false, | ||
children: ['mock-data', 'with-dva', 'load-on-demand', 'deploy'], | ||
}, | ||
{ | ||
title: 'Reference', | ||
collapsable: false, | ||
children: ['faq', 'migration', 'env-variables'], | ||
}, | ||
], | ||
'/config/': [''], | ||
'/api/': [''], | ||
'/plugin/': [ | ||
{ | ||
title: 'Plugin', | ||
collapsable: false, | ||
children: [''], | ||
}, | ||
{ | ||
title: 'Offcial Plugins', | ||
collapsable: false, | ||
children: ['umi-plugin-react'], | ||
}, | ||
{ | ||
title: 'Develop Plugin', | ||
collapsable: false, | ||
children: ['develop'], | ||
}, | ||
], | ||
}, | ||
{ | ||
title: '进阶', | ||
collapsable: false, | ||
children: ['mock-data', 'with-dva', 'load-on-demand', 'deploy'], | ||
}, | ||
{ | ||
title: '参考', | ||
collapsable: false, | ||
children: ['faq', 'migration', 'env-variables'], | ||
}, | ||
], | ||
'/config/': [''], | ||
'/api/': [''], | ||
'/plugin/': [ | ||
{ | ||
title: '插件', | ||
collapsable: false, | ||
children: [''], | ||
}, | ||
{ | ||
title: '官方插件', | ||
collapsable: false, | ||
children: ['umi-plugin-react'], | ||
}, | ||
{ | ||
title: '插件开发', | ||
collapsable: false, | ||
children: ['develop'], | ||
}, | ||
'/zh/': { | ||
selectText: '选择语言', | ||
label: '简体中文', | ||
editLinkText: '在 GitHub 上编辑此页', | ||
nav: [ | ||
{ text: '指南', link: '/guide/' }, | ||
{ text: '配置', link: '/config/' }, | ||
{ text: 'API', link: '/api/' }, | ||
{ text: '插件', link: '/plugin/' }, | ||
{ text: 'V1 文档', link: 'https://v1.umijs.org/' }, | ||
{ text: '发布日志', link: 'https://github.com/umijs/umi/releases' }, | ||
], | ||
sidebar: { | ||
'/zh/guide/': [ | ||
{ | ||
title: '指南', | ||
collapsable: false, | ||
children: [ | ||
'', | ||
'getting-started', | ||
'create-umi-app', | ||
'examples', | ||
'app-structure', | ||
'router', | ||
'navigate-between-pages', | ||
'config', | ||
'html-template', | ||
], | ||
}, | ||
{ | ||
title: '进阶', | ||
collapsable: false, | ||
children: ['mock-data', 'with-dva', 'load-on-demand', 'deploy'], | ||
}, | ||
{ | ||
title: '参考', | ||
collapsable: false, | ||
children: ['faq', 'migration', 'env-variables'], | ||
}, | ||
], | ||
'/zh/config/': [''], | ||
'/zh/api/': [''], | ||
'/zh/plugin/': [ | ||
{ | ||
title: '插件', | ||
collapsable: false, | ||
children: [''], | ||
}, | ||
{ | ||
title: '官方插件', | ||
collapsable: false, | ||
children: ['umi-plugin-react'], | ||
}, | ||
{ | ||
title: '插件开发', | ||
collapsable: false, | ||
children: ['develop'], | ||
}, | ||
], | ||
}, | ||
], | ||
}, | ||
}, | ||
}, | ||
}; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,4 +1,4 @@ | ||
$accentColor = #FD9111 | ||
$accentColor = #029ffd | ||
$textColor = #2c3e50 | ||
$borderColor = #eaecef | ||
$codeBgColor = #282c34 |
Empty file.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,48 +1,48 @@ | ||
--- | ||
home: true | ||
actionText: 快速上手 → | ||
actionText: Get Started → | ||
actionLink: /guide/ | ||
features: | ||
- title: 插件化 | ||
details: umi 的整个生命周期都是插件化的,甚至其内部实现就是由大量插件组成,比如 pwa、按需加载、一键切换 preact、一键兼容 ie9 等等,都是由插件实现。 | ||
- title: 开箱即用 | ||
details: 你只需一个 umi 依赖就可启动开发,无需安装 react、preact、webpack、react-router、babel、jest 等等。 | ||
- title: 约定式路由 | ||
details: 类 next.js 的约定式路由,无需再维护一份冗余的路由配置,支持权限、动态路由、嵌套路由等等。 | ||
- title: Pluggable | ||
details: The entire lifecycle of umi is composed of plugins, and such as pwa, on-demand loading, one-click switching preact, one-button compatibility ie9, etc., all implemented by plugins. | ||
- title: Out Of Box | ||
details: You only need a umi dependency to start development without having to install react, preact, webpack, react-router, babel, jest, and more. | ||
- title: Conventional Routing | ||
details: Next.js like and full featured routing conventions, support permissions, dynamic routing, nested routing, and more. | ||
footer: MIT Licensed | Copyright © 2017-present | ||
--- | ||
|
||
### 入门非常简单 | ||
### Getting started is very simple | ||
|
||
```bash | ||
# 安装 | ||
# Install deps | ||
$ yarn global add umi # 或者 npm install -g umi | ||
|
||
# 新建应用 | ||
# Create application | ||
$ mkdir myapp && cd myapp | ||
|
||
# 新建页面 | ||
# Create page | ||
$ umi generate page index | ||
|
||
# 本地开发 | ||
# Start dev server | ||
$ umi dev | ||
|
||
# 构建上线 | ||
# Build and deploy | ||
$ umi build | ||
``` | ||
|
||
[10 分钟入门 umi 视频版](https://youtu.be/vkAUGUlYm24) | ||
[Getting started with a 10 minutes video](https://youtu.be/vkAUGUlYm24) | ||
|
||
### 社区 | ||
## Community | ||
|
||
#### 钉钉群 | ||
### Telegram | ||
|
||
<img src="https://gw.alipayobjects.com/zos/rmsportal/wsBGpRlCOkmxHzMHuyAT.jpg" width="60" /> | ||
[https://t.me/joinchat/G0DdHw-44FO7Izt4K1lLFQ](https://t.me/joinchat/G0DdHw-44FO7Izt4K1lLFQ) | ||
|
||
#### 微信群 | ||
### 钉钉群 | ||
|
||
群满 100 人,请加 `sorryccpro` 好友备注 `umi` 邀请加入。 | ||
<img src="https://gw.alipayobjects.com/zos/rmsportal/wsBGpRlCOkmxHzMHuyAT.jpg" width="60" /> | ||
|
||
#### Telegram | ||
### 微信群 | ||
|
||
[https://t.me/joinchat/G0DdHw-44FO7Izt4K1lLFQ](https://t.me/joinchat/G0DdHw-44FO7Izt4K1lLFQ) | ||
群满 100 人,请加 `sorryccpro` 好友备注 `umi` 邀请加入。 |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.