鸿蒙入门到实战开发 - DevEco Studio 开发工具

HUAWEI DevEco Studio 基于IntelliJ IDEA Community开源版本定制开发,支持HarmonyOS和OpenHarmony应用及服务开发。

面向全场景多设备,提供一站式的分布式应用开发平台,支持分布式多端开发、分布式多端调测、多端模拟仿真,全方位的质量与安全保障。

DevEco Studio 3.1配套支持HarmonyOS 3.1版本及以上的应用及服务开发,提供了代码智能编辑、低代码开发、双向预览等功能,以及轻量构建工具DevEco Hvigor 、本地模拟器,持续提升应用及服务开发效率。

developer.harmonyos.com/cn/develop/...

下载安装完事遇到这么一个问题

ruby 复制代码
Unable to run 'npm install'.
	 Detail: See https://developer.harmonyos.com/en/docs/documentation/doc-guides/faq-development-environment-0000001168829643#section1311117111474
> hvigor ERROR: Sdk download failed.
> hvigor ERROR: BUILD FAILED in 9 s 401 ms 

刚上来创建一个项目

项目结构

安装文档执行这一步也失败了。。。

ruby 复制代码
Install task failed: JS 3.2.12.5.
Install JS dependencies failed.
Cause: Unable to run npm install.
Solution: See https://developer.harmonyos.com/cn/docs/documentation/doc-guides/faq-development-environment-0000001168829643#section1311117111474

文档说需要来这里清缓存,我打开后发现没有缓存但是也装模作样的清了一下

看到这些就是可以了

shell 复制代码
> hvigor 'npm install' executed
> hvigor Moving the SDK...
> hvigor Install task finished: ArkTS 3.2.12.5
> hvigor Installing Toolchains:3.2.3.6...
> hvigor Install task started: Toolchains 3.2.3.6
> hvigor Downloading https://update.dbankcdn.com/download/data/pub_13/HWHOTA_hota_900_9/cd/v3/6-Eg0KmCSpOpkqSEm-c8_w/toolchains-darwin-arm64-3.2.3.6-Release.zip...
> hvigor Unzipping /Users/xxx/Library/Huawei/Sdk/.temp/toolchains/3.2.3.6/install/toolchains-darwin-arm64-3.2.3.6-Release.zip...
> hvigor Moving the SDK...
> hvigor Install task finished: Toolchains 3.2.3.6
> hvigor Finished :entry:init... after 2 ms 
> hvigor Finished ::init... after 1 ms 

Process finished with exit code 0

运行App

lua 复制代码
The type of the target device does not match the deviceType configured in the module.json5 file of the selected module.

查了几个文档依然没有解决问题,好挫败啊

developer.huawei.com/consumer/cn...

blog.csdn.net/Calvin_zhou...

developer.huawei.com/consumer/cn...

我心想是不是没有模拟器、打算去下载一个模拟器,然后提示我需要先下载系统,玩呢?

然后我把这一堆都下载了

然后就安装了这个

可是我还么有运行起来程序,我累了。。。

相关推荐
万少2 小时前
2025中了 聊一聊程序员为什么都要做自己的产品
前端·harmonyos
幽蓝计划15 小时前
HarmonyOS NEXT仓颉开发语言实战案例:动态广场
华为·harmonyos
万少21 小时前
第五款 HarmonyOS 上架作品 奇趣故事匣 来了
前端·harmonyos·客户端
幽蓝计划1 天前
HarmonyOS NEXT仓颉开发语言实战案例:电影App
华为·harmonyos
HMS Core1 天前
HarmonyOS免密认证方案 助力应用登录安全升级
安全·华为·harmonyos
生如夏花℡1 天前
HarmonyOS学习记录3
学习·ubuntu·harmonyos
伍哥的传说1 天前
鸿蒙系统(HarmonyOS)应用开发之手势锁屏密码锁(PatternLock)
前端·华为·前端框架·harmonyos·鸿蒙
遇到困难睡大觉哈哈2 天前
HarmonyOS 公共事件机制介绍以及多进程之间的通信实现(9000字详解)
华为·harmonyos
幽蓝计划2 天前
HarmonyOS NEXT仓颉开发语言实战案例:外卖App
开发语言·harmonyos
伍哥的传说2 天前
鸿蒙系统(HarmonyOS)应用开发之实现电子签名效果
开发语言·前端·华为·harmonyos·鸿蒙·鸿蒙系统