文件最后提交记录最后更新时间
!1055 适配横屏修改 * adapter WGR 3 年前
!887 README整改 * readme update 3 年前
!392 Done! 全量翻译---JsWorker * Added English readme * Added English readme * Added English readme * Added English readme 4 年前
!966 README整改 * update README_zh.md 3 年前
!621 API7工程适配IDE900 API8 * update * update * update * adapter to IDE900 api8 4 年前
!621 API7工程适配IDE900 API8 * update * update * update * adapter to IDE900 api8 4 年前
!858 901适配 * Merge branch 'master' of gitee.com:openharmony/app_samples into master * nativeAPI、multiMedia * 901适配 * 格式 * 修改package.json的格式 * 901适配 3 年前
README.md

JsWorker

Introduction

This sample shows how to start a worker thread in JS and implement the communication between the worker thread and host thread.

Usage

  1. On the sample app, four strings are displayed on the home screen. After you touch Sort string array, these strings are sent to the worker thread. The worker thread sorts the strings and sends the result to the host thread. The host thread then displays the strings after sorting on the home screen.

  2. You can touch Clear to clear the strings after sorting.

Constraints

This sample can only be run on standard-system devices.