HarmonyOS smartwatch import system things error

Viewed 24

https://developer.harmonyos.com/en/docs/documentation/doc-references/js-apis-network-uploading-downloading-0000000000626076

I trying to import system things:

import network from '@system.network';
import vibrator from '@system.vibrator';
import request from '@system.request';

console.log("vibrator? " + vibrator);
console.log("network? " + network);
console.log("request? " + request);

[Debug] vibrator? [object Object] //working, found
[Debug] network? undefined //can't find
[Debug] request? undefined //can't find


7:58    Jerry Launcher: [JS Exception]: TypeError: Cannot read property 'download' of undefined
8:02    Jerry Launcher: [JS Exception]: TypeError: Cannot read property 'download' of undefined

Whats happening?

0 Answers
Related