# Codelabs_OpenHarmony
**Repository Path**: Mike_lee_is_coding/codelabs_openharmony
## Basic Information
- **Project Name**: Codelabs_OpenHarmony
- **Description**: 分享知识与见解,一起探索代码的独特魅力。
- **Primary Language**: Unknown
- **License**: Not specified
- **Default Branch**: master
- **Homepage**: None
- **GVP Project**: No
## Statistics
- **Stars**: 0
- **Forks**: 421
- **Created**: 2023-04-24
- **Last Updated**: 2023-04-24
## Categories & Tags
**Categories**: Uncategorized
**Tags**: None
## README
# OpenHarmony Codelabs
## 概要简介
为帮助开发者快速熟悉OpenHarmony的能力以及相关的应用开发流程,我们提供了一系列的基于趣味场景的应用示例,即Codelabs,开发者可以根据我们的文档一步步的学习和完成简单项目的开发。
## 目录
- 优秀案例
- [健康生活应用(ArkTS)](https://gitee.com/openharmony/codelabs/tree/master/ExcellentCase/Healthy_life)(API 9+)
- Ability开发
- [UIAbility内和UIAbility间页面的跳转(ArkTS)](https://gitee.com/openharmony/codelabs/tree/master/Ability/StageAbility)(API 9+)
- [Stage模型下Ability的创建和使用(ArkTS)](https://gitee.com/openharmony/codelabs/tree/master/Ability/StageAbilityDemo)(API 9+)
- [UIAbility内页面间的跳转(ArkTS)](https://gitee.com/openharmony/codelabs/tree/master/Ability/PagesRouter)(API 9+)
- [为应用添加运行时权限(ArkTS)(Full SDK)](https://gitee.com/openharmony/codelabs/tree/master/Ability/AccessPermission)(API 9+)
- UI(ArkTS)
- [一次开发多端部署(ArkTS)](https://gitee.com/openharmony/codelabs/tree/master/ETSUI/Multi_device)(API 9+)
- [ArkTS基础知识(ArkTS)](https://gitee.com/openharmony/codelabs/tree/master/ETSUI/RankingDemo)(API 9+)
- [动效示例(ArkTS)](https://gitee.com/openharmony/codelabs/tree/master/ETSUI/Animation)(API 9+)
- [转场动画的使用(ArkTS)](https://gitee.com/openharmony/codelabs/tree/master/ETSUI/TransitionAnimation)(API 9+)
- [自定义下拉刷新动画(ArkTS)](https://gitee.com/openharmony/codelabs/tree/master/ETSUI/AnimateRefresh)(API 9+)
- [ArkUI常用布局容器对齐方式(ArkTS)](https://gitee.com/openharmony/codelabs/tree/master/ETSUI/OHLayoutAlign)(API 9+)
- [常用组件与布局(ArkTS)](https://gitee.com/openharmony/codelabs/tree/master/ETSUI/ArkTSComponents)(API 9+)
- [Web组件的使用(ArkTS)](https://gitee.com/openharmony/codelabs/tree/master/ETSUI/WebCookie)(API 9+)
- [基础组件Slider的使用(ArkTS)](https://gitee.com/openharmony/codelabs/tree/master/ETSUI/SliderExample)(API 9+)
- [Web组件抽奖案例(ArkTS)](https://gitee.com/openharmony/codelabs/tree/master/ETSUI/WebComponent)(API 9+)
- [List组件的使用之商品列表(ArkTS)](https://gitee.com/openharmony/codelabs/tree/master/ETSUI/List)(API 9+)
- [List组件的使用之设置项(ArkTS)](https://gitee.com/openharmony/codelabs/tree/master/ETSUI/List_HDC)(API 9+)
- [像素转换(ArkTS)](https://gitee.com/openharmony/codelabs/tree/master/ETSUI/PixelUnitsDemo)(API 9+)
- [极简声明式UI范式(ArkTS)](https://gitee.com/openharmony/codelabs/tree/master/ETSUI/SimpleGalleryEts)(API 8+)
- [购物应用(ArkTS)](https://gitee.com/openharmony/codelabs/tree/master/ETSUI/ShoppingEts)(API 8+)
- [流式布局(ArkTS)](https://gitee.com/openharmony/codelabs/tree/master/ETSUI/FlowLayoutEts)(API 8+)
- [弹窗(ArkTS)](https://gitee.com/openharmony/codelabs/tree/master/ETSUI/CustomDialogEts)(API 8+)
- UI(JS)
- [image、image-animator(JS)](https://gitee.com/openharmony/codelabs/tree/master/JSUI/ClickableJsDemo)(API 8+)
- [input、label(JS)](https://gitee.com/openharmony/codelabs/tree/master/JSUI/InputApplication)(API 8+)
- [rating(JS)](https://gitee.com/openharmony/codelabs/tree/master/JSUI/RatingApplication)(API 8+)
- [slider(JS)](https://gitee.com/openharmony/codelabs/tree/master/JSUI/SliderApplication)(API 8+)
- [switch、chart(JS)](https://gitee.com/openharmony/codelabs/tree/master/JSUI/SwitchApplication)(API 8+)
- [dialog(JS)](https://gitee.com/openharmony/codelabs/tree/master/JSUI/DialogDemo)(API 8+)
- [动画样式(JS)](https://gitee.com/openharmony/codelabs/tree/master/JSUI/AnimationDemo)(API 8+)
- [购物应用(JS)](https://gitee.com/openharmony/codelabs/tree/master/JSUI/ShoppingOpenHarmony)(API 8+)
- [自定义组件(JS)](https://gitee.com/openharmony/codelabs/tree/master/JSUI/JSCanvasComponet)(API 8+)
- 公共事件与通知
- [闹钟(ArkTS)](https://gitee.com/openharmony/codelabs/tree/master/CommonEventAndNotification/AlarmClock)(API 9+)
- 媒体
- [音频播放器(ArkTS)](https://gitee.com/openharmony/codelabs/tree/master/Media/Audio_OH_ETS)(API 9+)
- [视频播放器(ArkTS)(Full SDK)](https://gitee.com/openharmony/codelabs/tree/master/Media/VideoPlayerStage)(API 9+)
- [图片编辑模板(JS)](https://gitee.com/openharmony/codelabs/tree/master/Media/ImageEditorTemplate)(API 8+)
- [图片常见操作(JS)](https://gitee.com/openharmony/codelabs/tree/master/Media/ImageJsDemo)(API 8+)
- [简易视频播放器(JS)](https://gitee.com/openharmony/codelabs/tree/master/Media/VideoOpenHarmony)(API 8+)
- 网络管理
- [新闻数据加载(ArkTS)](https://gitee.com/openharmony/codelabs/tree/master/NetworkManagement/NewsDataArkTS)(API 9+)
- [使用UDP实现与服务端通信(ArkTS)](https://gitee.com/openharmony/codelabs/tree/master/NetworkManagement/UdpDemoOH)(API 9+)
- [使用HTTP实现与服务端通信(ArkTS)](https://gitee.com/openharmony/codelabs/tree/master/NetworkManagement/SmartChatEtsOH)(API 9+)
- [使用TCP实现与服务端通信(ArkTS)](https://gitee.com/openharmony/codelabs/tree/master/NetworkManagement/TcpSocketDemo)(API 9+)
- 数据库
- [关系型数据库(ArkTS)](https://gitee.com/openharmony/codelabs/tree/master/Data/Rdb)(API 9+)
- [首选项(ArkTS)](https://gitee.com/openharmony/codelabs/tree/master/Data/Preferences)(API 9+)
- [应用内字体大小调节(ArkTS)](https://gitee.com/openharmony/codelabs/tree/master/Data/SetAppFontSize)(API 9+)
- [应用的首次启动(ArkTS)](https://gitee.com/openharmony/codelabs/tree/master/Data/FirstStartDemo)(API 9+)
- [字符串加解密(ArkTS)](https://gitee.com/openharmony/codelabs/tree/master/Data/StringCipherETS)(API 9+)
- [备忘录(ArkTS)](https://gitee.com/openharmony/codelabs/tree/master/Data/NotePad_OH_ETS)(API 8+)
- [关系型数据库(JS)](https://gitee.com/openharmony/codelabs/tree/master/Data/JSRelationshipData)(API 8+)
- [轻量级偏好数据库(JS)](https://gitee.com/openharmony/codelabs/tree/master/Data/Database)(API 8+)
- [分布式数据库(JS)](https://gitee.com/openharmony/codelabs/tree/master/Data/JsDistributedData)(API 8+)
- 分布式
- [分布式手写板(ArkTS)(Full SDK)](https://gitee.com/openharmony/codelabs/tree/master/Distributed/DistributeDatabaseDrawEts)(API 8+)
- [分布式游戏手柄(ArkTS)(Full SDK)](https://gitee.com/openharmony/codelabs/tree/master/Distributed/HandleGameApplication)(API 8+)
- [分布式邮件(ArkTS)(Full SDK)](https://gitee.com/openharmony/codelabs/tree/master/Distributed/OHMailETS)(API 8+)
- [分布式亲子早教系统(ArkTS)(Full SDK)](https://gitee.com/openharmony/codelabs/tree/master/Distributed/OpenHarmonyPictureGame)(API 8+)
- [分布式遥控器(ArkTS)(Full SDK)](https://gitee.com/openharmony/codelabs/tree/master/Distributed/RemoteControllerETS)(API 8+)
- [分布式调度启动远程FA(JS)](https://gitee.com/openharmony/codelabs/tree/master/Distributed/RemoteStartFA)(API 8+)
- [分布式新闻客户端(JS)](https://gitee.com/openharmony/codelabs/tree/master/Distributed/NewsDemo)(API 8+)
- [分布式鉴权(JS)](https://gitee.com/openharmony/codelabs/tree/master/Distributed/GameAuthOpenH)(API 8+)
- NativeAPI
- [第一个Native C++应用(ArkTS)](https://gitee.com/openharmony/codelabs/tree/master/NativeAPI/NativeTemplateDemo)(API 9+)
- [Native Component(ArkTS)](https://gitee.com/openharmony/codelabs/tree/master/NativeAPI/XComponent)(API 9+)
- 三方库
- [库的调用(ArkTS)](https://gitee.com/openharmony/codelabs/tree/master/ThirdPartyComponents/ThirdPartyLibrary)(API 9+)
- [VCard(ArkTS)](https://gitee.com/openharmony/codelabs/tree/master/ThirdPartyComponents/VCardDemo)(API 9+)
- 效率提升套件
- [常用组件和容器低代码开发示例(ArkTS)](https://gitee.com/openharmony/codelabs/tree/master/EfficiencyEnhancementKit/SuperVisualSample)(API 9+)
- 图形图像
- [手势截屏(ArkTS)(Full SDK)](https://gitee.com/openharmony/codelabs/tree/master/GraphicImage/GestureScreenshot)(API 9+)
## 使用说明
1. 将独立的应用示例工程导入DevEco Studio进行编译构建及运行调试。
2. 部分应用示例中含有多个模块,开发者可以选择对单个模块进行编译构建,生成一个HAP应用安装包,也可以对整个工程进行编译构建,生成多个HAP应用安装包。
3. 安装运行后,即可在设备上查看应用示例运行效果,以及进行相关调试。
## 约束与限制
安装应用示例之前,请先查看"README_zh.md"文件来确认应用示例是否为stage模型,若为Stage模型需要查看entry/src/main路径下的module.json5文件中的"deviceType"字段来确认该应用支持的设备类型;否则为FA模型,查看entry/src/main路径下的config.json文件中的"deviceType"字段来确认该应用示例支持的设备类型,两种模型都可尝试通过修改该字段使其可以在相应类型的设备上运行。