NEWS
node-fetch als zusätzliches Modul
-
Ist node-fetch als zusätzliches Modul (node-fetch@2) in nodejs Vers. 22
noch notwendig wenn man fetch() verwenden will?Wenn nein, dann wie entferne ich alle zusätzlichen node-fetch npm Module?
root@raspberrypi5:/opt/iobroker# npm ls node-fetch
iobroker.inst@3.0.0 /opt/iobroker
├─┬ @iobroker-javascript.0/svrooij-evohome@npm:@svrooij/evohome@1.0.2
│ └── node-fetch@2.7.0
├─┬ iobroker.backitup@3.3.10
│ ├─┬ google-auth-library@10.5.0
│ │ └─┬ gaxios@7.1.3
│ │ └── node-fetch@3.3.2 deduped
│ └─┬ webdav@5.8.0
│ ├─┬ @buttercup/fetch@0.2.1
│ │ └── node-fetch@3.3.2 deduped
│ └── node-fetch@3.3.2
└─┬ iobroker.email@2.0.4
└─┬ googleapis@146.0.0
└─┬ google-auth-library@9.15.1
└─┬ gaxios@6.7.1
└── node-fetch@2.7.0Bitte ein ganz einfaches komplettes Beispiel so wie:
async function Test(){
log('async Funktion Test')
var out = await fetch('https://api.weather.gov/gridpoints/OKX/35,35/forecast')
log ('Antwort: '+out)
}
log('--- Start ---')
Test()
log('--- Ende ---') -
Ist node-fetch als zusätzliches Modul (node-fetch@2) in nodejs Vers. 22
noch notwendig wenn man fetch() verwenden will?Wenn nein, dann wie entferne ich alle zusätzlichen node-fetch npm Module?
root@raspberrypi5:/opt/iobroker# npm ls node-fetch
iobroker.inst@3.0.0 /opt/iobroker
├─┬ @iobroker-javascript.0/svrooij-evohome@npm:@svrooij/evohome@1.0.2
│ └── node-fetch@2.7.0
├─┬ iobroker.backitup@3.3.10
│ ├─┬ google-auth-library@10.5.0
│ │ └─┬ gaxios@7.1.3
│ │ └── node-fetch@3.3.2 deduped
│ └─┬ webdav@5.8.0
│ ├─┬ @buttercup/fetch@0.2.1
│ │ └── node-fetch@3.3.2 deduped
│ └── node-fetch@3.3.2
└─┬ iobroker.email@2.0.4
└─┬ googleapis@146.0.0
└─┬ google-auth-library@9.15.1
└─┬ gaxios@6.7.1
└── node-fetch@2.7.0Bitte ein ganz einfaches komplettes Beispiel so wie:
async function Test(){
log('async Funktion Test')
var out = await fetch('https://api.weather.gov/gridpoints/OKX/35,35/forecast')
log ('Antwort: '+out)
}
log('--- Start ---')
Test()
log('--- Ende ---')@hanss sagte in node-fetch als zusätzlicher Adapter:
root@raspberrypi5
Das ist ganz sicher NICHT notwendig. Lass den Scheiß mit dem root-Login.
Die Verwendung von node-fetch als SubDependency kannst du nicht direkt beeinflussen (auch nicht als root), da müssen die jeweiligen Module anders aufgesetzt werden.
Zum Thema: