Skip to content

Commit 195b45e

Browse files
committed
feat: add tutorial video button
1 parent 3ef6f9f commit 195b45e

File tree

4 files changed

+20
-9
lines changed

4 files changed

+20
-9
lines changed

docs/tutorial/02-getting-started/09-extension-integration.md

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -47,8 +47,12 @@ pnpm add @alova/wormhole -D
4747

4848
Install `@alova/wormhole` and alova's vscode extension at the same time to enjoy the complete features. `@alova/wormhole` provides automatic generation features. The vscode extension can quickly call `@alova/wormhole` and provide shortcut keys for quickly finding interface documents in the editor.
4949

50+
:::info WebStorm editor tips
51+
5052
If you are using an editor such as WebStorm, you can use [@alova/wormhole's commands](/api/wormhole#commands) to automatically generate API call functions, complete TypeScript types of APIs, and API documentation information.
5153

54+
:::
55+
5256
## Configuration
5357

5458
When using the extension, you need to specify the input source and output directory from the openapi file, etc. You can create a configuration file in the project root directory, which supports the following formats:

i18n/zh-CN/code.json

Lines changed: 5 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -466,7 +466,10 @@
466466
"message": "快速开始",
467467
"description": "开始按钮文字"
468468
},
469-
469+
"homepage.5-minute Video Tutorial": {
470+
"message": "5分钟入门视频",
471+
"description": "快速入门按钮文字"
472+
},
470473
"homepage.features.Simple and familiar": {
471474
"message": "简单熟悉",
472475
"description": "简单熟悉"
@@ -499,16 +502,14 @@
499502
"message": "4kb+,只有axios的30%",
500503
"description": "description of feature"
501504
},
502-
503505
"homepage.availableScope.title": {
504-
"message": "🎉打破useHook使用边界",
506+
"message": "打破useHook使用边界",
505507
"description": "description of available scope"
506508
},
507509
"homepage.availableScope.subtitle": {
508510
"message": "现在,alova已经完美兼容了vue options,尽情使用吧!",
509511
"description": "description of available scope desc"
510512
},
511-
512513
"homepage.strategy.title": {
513514
"message": "以声明的方式完成你的请求",
514515
"description": "description of request strategy"
@@ -781,7 +782,6 @@
781782
"message": "查看详情",
782783
"description": "description of btnDetail of strategy"
783784
},
784-
785785
"homepage.support.title": {
786786
"message": "与任何请求工具在任何JS环境下运行",
787787
"description": "description of support title"
@@ -790,7 +790,6 @@
790790
"message": "use hooks起源于functional component, 但alova创新性地将它兼容了options和class风格的UI框架,这意味着alova的use hooks几乎不受JS环境和UI框架限制,并且可以与你熟悉的请求工具一起使用",
791791
"description": "description of support subtitle"
792792
},
793-
794793
"homepage.contributors.title": {
795794
"message": "感谢有你们",
796795
"description": "description of contributors title"
@@ -799,7 +798,6 @@
799798
"message": "alova贡献者们的智慧和力量,正在让alova变得越来越完美",
800799
"description": "description of contributors subtitle"
801800
},
802-
803801
"homepage.like.title": {
804802
"message": "如果你也喜欢alova",
805803
"description": "description of support title"
@@ -824,7 +822,6 @@
824822
"message": "alova v3已发布",
825823
"description": "description of release announce"
826824
},
827-
828825
"ad.project collection": {
829826
"message": "alova用在项目里了吗?快来告诉我",
830827
"description": "description of ad.project collection"

i18n/zh-CN/docusaurus-plugin-content-docs/current/tutorial/02-getting-started/09-extension-integration.md

Lines changed: 5 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -47,7 +47,11 @@ pnpm add @alova/wormhole -D
4747

4848
同时安装`@alova/wormhole`和 alova 的 vscode 扩展可以享受到完整的特性,`@alova/wormhole`提供自动生成特性,vscode 扩展可以快速调用`@alova/wormhole`的能力,并提供在编辑器中快速查找接口文档的快捷键。
4949

50-
如果你正在使用 WebStorm 等编辑器,你可以通过 [@alova/wormhole 的命令](/api/wormhole#commands) 来自动生成 api 调用函数、api 的完整 TypeScript 类型和 api 文档信息。
50+
:::info WebStorm 编辑器说明
51+
52+
如果你正在使用 WebStorm 等非 vscode 系列的编辑器,你可以通过 [@alova/wormhole 的命令](/api/wormhole#commands) 来自动生成 api 调用函数、api 的完整 TypeScript 类型和 api 文档信息。
53+
54+
:::
5155

5256
## 配置
5357

src/pages/index.tsx

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -22,6 +22,12 @@ const buttons = [
2222
style: 'ctw-button-primary',
2323
link: '/tutorial/getting-started/introduce'
2424
},
25+
{
26+
text: <Translate id="homepage.5-minute Video Tutorial">5-minute Video Tutorial</Translate>,
27+
type: 'primary',
28+
style: 'ctw-button-primary',
29+
link: '/video-tutorial'
30+
},
2531
{
2632
text: <Translate id="homepage.Examples">Examples</Translate>,
2733
type: 'secondary',

0 commit comments

Comments
 (0)