Skip to content

Commit 7260594

Browse files
committed
docs: Update READMEs for v4.x changes
1 parent 25b1ca7 commit 7260594

File tree

5 files changed

+51
-33
lines changed

5 files changed

+51
-33
lines changed

CHANGELOG.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -15,7 +15,7 @@
1515
- Add initial package and tsconfig for components and core &nbsp;-&nbsp; by @Marinerer [<samp>(5deba)</samp>](https://github.com/Marinerer/unity-webgl/commit/5deba6b)
1616
- Add UnityWebglComponent for Vue integration &nbsp;-&nbsp; by @Marinerer [<samp>(68e23)</samp>](https://github.com/Marinerer/unity-webgl/commit/68e237e)
1717
- Add comprehensive UnityWebgl testing suite &nbsp;-&nbsp; by @Marinerer [<samp>(82330)</samp>](https://github.com/Marinerer/unity-webgl/commit/823307c)
18-
-
18+
1919
### &nbsp;&nbsp;&nbsp;📝 Documentation
2020

2121
- Add documentation &nbsp;-&nbsp; by @Marinerer [<samp>(f0411)</samp>](https://github.com/Marinerer/unity-webgl/commit/f041121)

README.md

Lines changed: 9 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,8 @@
11
# unity-webgl
22

33
[![version](https://img.shields.io/npm/v/unity-webgl?style=flat-square)](https://www.npmjs.com/package/unity-webgl)
4+
[![codecov](https://codecov.io/gh/Marinerer/unity-webgl/graph/badge.svg?token=7J0R98DRUB)](https://codecov.io/gh/Marinerer/unity-webgl)
5+
[![release](https://img.shields.io/github/actions/workflow/status/Marinerer/unity-webgl/release.yml?style=flat-square)](https://github.com/Marinerer/unity-webgl/releases)
46
[![downloads](https://img.shields.io/npm/dm/unity-webgl?style=flat-square)](https://www.npmjs.com/package/unity-webgl)
57
[![size](https://img.shields.io/bundlephobia/minzip/unity-webgl?style=flat-square)](https://bundlephobia.com/package/unity-webgl)
68
[![license](https://img.shields.io/npm/l/unity-webgl?style=flat-square)](https://github.com/Marinerer/unity-webgl)
@@ -9,8 +11,9 @@
911

1012
`unity-webgl` provides an easy solution for embedding `Unity WebGL` builds in your web applications, with two-way communication and interaction between your webApp and Unity application with advanced API's.
1113

12-
> Framework agnostic, usable in any web project.
13-
> Currently includes Vue components, supporting both Vue 2/3.
14+
> 🚨 Reminder
15+
>
16+
> `v4.x` has been updated significantly and the API is not compatible with `v3.x` and earlier versions. For upgrades, please refer to [Changelogs](https://github.com/Marinerer/unity-webgl/wiki/Major-changes-in-v4)
1417
1518
Based on [react-unity-webgl](https://github.com/jeffreylanters/react-unity-webgl)
1619

@@ -118,10 +121,10 @@ Initializes the Unity application's configuration items.
118121

119122
| Property | Type | Description | Required |
120123
| ------------------------ | ------- | -------------------------------------------------------------------------------------------------- | -------- |
121-
| `loaderUrl` | string | Unity resource loader file ||
122-
| `dataUrl` | string | File containing resource data and scenes ||
123-
| `frameworkUrl` | string | File with runtime and plugin code ||
124-
| `codeUrl` | string | WebAssembly binary file with native code ||
124+
| `loaderUrl` | string | Unity resource loader file | |
125+
| `dataUrl` | string | File containing resource data and scenes | |
126+
| `frameworkUrl` | string | File with runtime and plugin code | |
127+
| `codeUrl` | string | WebAssembly binary file with native code | |
125128
| `streamingAssetsUrl` | string | URL for streaming resources | Optional |
126129
| `memoryUrl` | string | URL for generated framework files | Optional |
127130
| `symbolsUrl` | string | URL for generated Unity code files | Optional |

README.zh_CN.md

Lines changed: 16 additions & 10 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,8 @@
11
# unity-webgl
22

33
[![version](https://img.shields.io/npm/v/unity-webgl?style=flat-square)](https://www.npmjs.com/package/unity-webgl)
4+
[![codecov](https://codecov.io/gh/Marinerer/unity-webgl/graph/badge.svg?token=7J0R98DRUB)](https://codecov.io/gh/Marinerer/unity-webgl)
5+
[![release](https://img.shields.io/github/actions/workflow/status/Marinerer/unity-webgl/release.yml?style=flat-square)](https://github.com/Marinerer/unity-webgl/releases)
46
[![downloads](https://img.shields.io/npm/dm/unity-webgl?style=flat-square)](https://www.npmjs.com/package/unity-webgl)
57
[![size](https://img.shields.io/bundlephobia/minzip/unity-webgl?style=flat-square)](https://bundlephobia.com/package/unity-webgl)
68
[![license](https://img.shields.io/npm/l/unity-webgl?style=flat-square)](https://github.com/Marinerer/unity-webgl)
@@ -9,17 +11,19 @@
911

1012
`unity-webgl` 提供了一个简单的解决方案,用于将 `Unity WebGL` 构建嵌入到 Web 应用程序中,同时为 Unity 和 WebApp 应用之间的双向通信和交互提供 API。
1113

12-
> 无框架限制,可用于任何 Web 项目。
13-
> 目前仅内置vue组件,支持 `vue2/3`
14+
> 🚨 提醒
15+
>
16+
> `v4.x` 版本进行了较大更新,API 不兼容 `v3.x`及之前版本。升级请参考 [变更信息](https://github.com/Marinerer/unity-webgl/wiki/Major-changes-in-v4)
17+
1418

1519
Based on [react-unity-webgl](https://github.com/jeffreylanters/react-unity-webgl)
1620

1721
## Features
1822

19-
📦 集成简单,无框架限制
20-
📩 支持 `WebApp``Unity` 双向通信和交互
21-
⏰ 全面的事件处理机制
22-
🧲 内置 `vue` 组件 (vue2/3)
23+
- 📦 集成简单,无框架限制
24+
- 📩 支持 `WebApp``Unity` 双向通信和交互
25+
- ⏰ 全面的事件处理机制
26+
- 🧲 内置 `vue` 组件 (`vue2/3`)
2327

2428
## Installation
2529

@@ -118,10 +122,10 @@ unityContext.create(canvas: HTMLCanvasElement | string)
118122

119123
| Property | Type | Description | Required |
120124
| ------------------------ | ------- | ------------------------------------------------------------------------------------- | -------- |
121-
| `loaderUrl` | string | Unity 资源加载器文件 ||
122-
| `dataUrl` | string | 包含资源数据和场景的文件 ||
123-
| `frameworkUrl` | string | 包含运行时和插件代码的文件 ||
124-
| `codeUrl` | string | 包含原生代码的 WebAssembly 二进制文件 ||
125+
| `loaderUrl` | string | Unity 资源加载器文件 | |
126+
| `dataUrl` | string | 包含资源数据和场景的文件 | |
127+
| `frameworkUrl` | string | 包含运行时和插件代码的文件 | |
128+
| `codeUrl` | string | 包含原生代码的 WebAssembly 二进制文件 | |
125129
| `streamingAssetsUrl` | string | 流媒体资源的 URL | 可选 |
126130
| `memoryUrl` | string | 生成的框架文件的 URL | 可选 |
127131
| `symbolsUrl` | string | 生成的 Unity 代码文件的 URL | 可选 |
@@ -329,6 +333,8 @@ public class WebGLPluginJS : MonoBehaviour
329333
- [调试 WebGL 构建并排除故障](https://docs.unity3d.com/cn/2023.2/Manual/webgl-debugging.html)
330334
- [WebGL 性能考虑因素](https://docs.unity3d.com/cn/2023.2/Manual/webgl-performance.html)
331335

336+
337+
332338
## License
333339

334340
MIT License

lib/core/README.md

Lines changed: 9 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,8 @@
11
# unity-webgl
22

33
[![version](https://img.shields.io/npm/v/unity-webgl?style=flat-square)](https://www.npmjs.com/package/unity-webgl)
4+
[![codecov](https://codecov.io/gh/Marinerer/unity-webgl/graph/badge.svg?token=7J0R98DRUB)](https://codecov.io/gh/Marinerer/unity-webgl)
5+
[![release](https://img.shields.io/github/actions/workflow/status/Marinerer/unity-webgl/release.yml?style=flat-square)](https://github.com/Marinerer/unity-webgl/releases)
46
[![downloads](https://img.shields.io/npm/dm/unity-webgl?style=flat-square)](https://www.npmjs.com/package/unity-webgl)
57
[![size](https://img.shields.io/bundlephobia/minzip/unity-webgl?style=flat-square)](https://bundlephobia.com/package/unity-webgl)
68
[![license](https://img.shields.io/npm/l/unity-webgl?style=flat-square)](https://github.com/Marinerer/unity-webgl)
@@ -9,8 +11,9 @@
911

1012
`unity-webgl` provides an easy solution for embedding `Unity WebGL` builds in your web applications, with two-way communication and interaction between your webApp and Unity application with advanced API's.
1113

12-
> Framework agnostic, usable in any web project.
13-
> Currently includes Vue components, supporting both Vue 2/3.
14+
> 🚨 Reminder
15+
>
16+
> `v4.x` has been updated significantly and the API is not compatible with `v3.x` and earlier versions. For upgrades, please refer to [Changelogs](https://github.com/Marinerer/unity-webgl/wiki/Major-changes-in-v4)
1417
1518
Based on [react-unity-webgl](https://github.com/jeffreylanters/react-unity-webgl)
1619

@@ -118,10 +121,10 @@ Initializes the Unity application's configuration items.
118121

119122
| Property | Type | Description | Required |
120123
| ------------------------ | ------- | -------------------------------------------------------------------------------------------------- | -------- |
121-
| `loaderUrl` | string | Unity resource loader file ||
122-
| `dataUrl` | string | File containing resource data and scenes ||
123-
| `frameworkUrl` | string | File with runtime and plugin code ||
124-
| `codeUrl` | string | WebAssembly binary file with native code ||
124+
| `loaderUrl` | string | Unity resource loader file | |
125+
| `dataUrl` | string | File containing resource data and scenes | |
126+
| `frameworkUrl` | string | File with runtime and plugin code | |
127+
| `codeUrl` | string | WebAssembly binary file with native code | |
125128
| `streamingAssetsUrl` | string | URL for streaming resources | Optional |
126129
| `memoryUrl` | string | URL for generated framework files | Optional |
127130
| `symbolsUrl` | string | URL for generated Unity code files | Optional |

lib/core/README.zh_CN.md

Lines changed: 16 additions & 10 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,8 @@
11
# unity-webgl
22

33
[![version](https://img.shields.io/npm/v/unity-webgl?style=flat-square)](https://www.npmjs.com/package/unity-webgl)
4+
[![codecov](https://codecov.io/gh/Marinerer/unity-webgl/graph/badge.svg?token=7J0R98DRUB)](https://codecov.io/gh/Marinerer/unity-webgl)
5+
[![release](https://img.shields.io/github/actions/workflow/status/Marinerer/unity-webgl/release.yml?style=flat-square)](https://github.com/Marinerer/unity-webgl/releases)
46
[![downloads](https://img.shields.io/npm/dm/unity-webgl?style=flat-square)](https://www.npmjs.com/package/unity-webgl)
57
[![size](https://img.shields.io/bundlephobia/minzip/unity-webgl?style=flat-square)](https://bundlephobia.com/package/unity-webgl)
68
[![license](https://img.shields.io/npm/l/unity-webgl?style=flat-square)](https://github.com/Marinerer/unity-webgl)
@@ -9,17 +11,19 @@
911

1012
`unity-webgl` 提供了一个简单的解决方案,用于将 `Unity WebGL` 构建嵌入到 Web 应用程序中,同时为 Unity 和 WebApp 应用之间的双向通信和交互提供 API。
1113

12-
> 无框架限制,可用于任何 Web 项目。
13-
> 目前仅内置vue组件,支持 `vue2/3`
14+
> 🚨 提醒
15+
>
16+
> `v4.x` 版本进行了较大更新,API 不兼容 `v3.x`及之前版本。升级请参考 [变更信息](https://github.com/Marinerer/unity-webgl/wiki/Major-changes-in-v4)
17+
1418

1519
Based on [react-unity-webgl](https://github.com/jeffreylanters/react-unity-webgl)
1620

1721
## Features
1822

19-
📦 集成简单,无框架限制
20-
📩 支持 `WebApp``Unity` 双向通信和交互
21-
⏰ 全面的事件处理机制
22-
🧲 内置 `vue` 组件 (vue2/3)
23+
- 📦 集成简单,无框架限制
24+
- 📩 支持 `WebApp``Unity` 双向通信和交互
25+
- ⏰ 全面的事件处理机制
26+
- 🧲 内置 `vue` 组件 (`vue2/3`)
2327

2428
## Installation
2529

@@ -118,10 +122,10 @@ unityContext.create(canvas: HTMLCanvasElement | string)
118122

119123
| Property | Type | Description | Required |
120124
| ------------------------ | ------- | ------------------------------------------------------------------------------------- | -------- |
121-
| `loaderUrl` | string | Unity 资源加载器文件 ||
122-
| `dataUrl` | string | 包含资源数据和场景的文件 ||
123-
| `frameworkUrl` | string | 包含运行时和插件代码的文件 ||
124-
| `codeUrl` | string | 包含原生代码的 WebAssembly 二进制文件 ||
125+
| `loaderUrl` | string | Unity 资源加载器文件 | |
126+
| `dataUrl` | string | 包含资源数据和场景的文件 | |
127+
| `frameworkUrl` | string | 包含运行时和插件代码的文件 | |
128+
| `codeUrl` | string | 包含原生代码的 WebAssembly 二进制文件 | |
125129
| `streamingAssetsUrl` | string | 流媒体资源的 URL | 可选 |
126130
| `memoryUrl` | string | 生成的框架文件的 URL | 可选 |
127131
| `symbolsUrl` | string | 生成的 Unity 代码文件的 URL | 可选 |
@@ -329,6 +333,8 @@ public class WebGLPluginJS : MonoBehaviour
329333
- [调试 WebGL 构建并排除故障](https://docs.unity3d.com/cn/2023.2/Manual/webgl-debugging.html)
330334
- [WebGL 性能考虑因素](https://docs.unity3d.com/cn/2023.2/Manual/webgl-performance.html)
331335

336+
337+
332338
## License
333339

334340
MIT License

0 commit comments

Comments
 (0)