miniget is a node module and properly imported via const miniget = require('miniget'); no error gets generated (like invalid function etc.) when using it, this should work as we are using webpack. The second example fetches a javascript file which is 1.1 MB in size, could that be an issue? Since, both miniget and fetch are not throwing any kind of error I guess the limitation is from Cloudflare infrastructure side? Are there any limits on how much we can fetch from remote servers?
The fetch works in the main index.js script but not when executed from another script which I am importing using const sig = require("./process.js"); ? This seems something CF specific, how to make this work?