在进行跨模块跳转时,发生报错hap path error,具体报错内容如下:
11-25 10:48:06.833 1394-1394 C03f00/ArkCompiler com.examp...20596468 F [default] [LoadJSPandaFile:113] resolveBufferCallback get hsp buffer failed, hsp path:/data/storage/el1/bundle/feature/ets/modules.abc, errorMsg:hap path error: /data/storage/el1/bundle/feature.hsp
// module.json5文件
{
"module": {
"name": "feature",
"type": "feature" // type类型为feature,此模块为HAP模块
}
} 查看对应模块中module.json5中的type为feature类型,该模块是HAP模块,而跨模块仅跳转支持HAR/HSP模块,不支持HAP模块。此外,目标页面未使用NavDestination组件,即使配置都正确页面也会显示空白,需要使用NavDestination组件包裹。