Skip to content

Commit 9563e18

Browse files
committed
website: Add environment-setup/android
1 parent e416f1c commit 9563e18

File tree

6 files changed

+38
-0
lines changed

6 files changed

+38
-0
lines changed
Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,6 @@
1+
Android 环境安装(for Windows)
2+
---
3+
4+
这里介绍,使用 React Native CLI 运行一个 Android 环境下的 app。
5+
6+
正在编辑中....
Lines changed: 11 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,11 @@
1+
import Markdown, { importAll } from '../../../../component/Markdown';
2+
3+
export default class Page extends Markdown {
4+
path = "/website/src/pages/docs/environment-setup/android-windows/README.md";
5+
getMarkdown = async () => {
6+
const md = await import('./README.md');
7+
// 支持 markdown 中,相对于当前 index.tsx 相对路径引入图片资源
8+
importAll((require as any).context('./', true, /\.(png|gif|jpg)$/), this.imageFiles);
9+
return md.default || md;
10+
}
11+
}
Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,6 @@
1+
Android 环境安装(for Mac)
2+
---
3+
4+
这里介绍,使用 React Native CLI 运行一个 Android 环境下的 app。
5+
6+
正在编辑中....
Lines changed: 11 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,11 @@
1+
import Markdown, { importAll } from '../../../../component/Markdown';
2+
3+
export default class Page extends Markdown {
4+
path = "/website/src/pages/docs/environment-setup/android/README.md";
5+
getMarkdown = async () => {
6+
const md = await import('./README.md');
7+
// 支持 markdown 中,相对于当前 index.tsx 相对路径引入图片资源
8+
importAll((require as any).context('./', true, /\.(png|gif|jpg)$/), this.imageFiles);
9+
return md.default || md;
10+
}
11+
}

website/src/routes/menus.ts

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -44,5 +44,6 @@ export const docsMenus: MenuData[] = [
4444
{ path: '/docs/getting-started', name: '快速上手' },
4545
{ divider: true, name: "环境安装" },
4646
{ path: '/docs/environment-setup/ios', name: 'iOS 环境安装' },
47+
{ path: '/docs/environment-setup/android', name: 'Android 环境安装(Mac)' },
4748
{ href: 'https://github.com/uiwjs/react-native-uiw/releases', target: '_blank', name: '更新日志' },
4849
]

website/src/routes/router.tsx

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -42,6 +42,9 @@ export const getRouterData = {
4242
'/docs/environment-setup/ios': {
4343
component: dynamicWrapper([], () => import('../pages/docs/environment-setup/ios')),
4444
},
45+
'/docs/environment-setup/android': {
46+
component: dynamicWrapper([], () => import('../pages/docs/environment-setup/android')),
47+
},
4548
'/docs/getting-started': {
4649
component: dynamicWrapper([], () => import('../pages/docs/getting-started')),
4750
},

0 commit comments

Comments
 (0)