deno_std
deno_std copied to clipboard
Node built-in https module implementation into deno's std/node library
Is your feature request related to a problem? Please describe. I would like to use the google-spreadsheet module, more specifically the skypack version of it with deno, but it requires the https node module and according to the std manual the Node built-in https module is not currently implemented.
When running:
import { GoogleSpreadsheet } from "https://cdn.skypack.dev/google-spreadsheet";
import credentials from "./mycredfile" assert { type: "json"}
const doc = new GoogleSpreadsheet("doc id");
await doc.useServiceAccountAuth(credentials);
I get the following error:
error: Uncaught Error: [Package Error] "https" does not exist. (Imported by "gaxios").
throw new Error("[Package Error] \"https\" does not exist. (Imported by \"gaxios\").");
^
at https://cdn.skypack.dev/error/node:https?from=gaxios:14:7
Describe the solution you'd like The solution I would like is for the Node built-in https module to be implemented into the Deno standard library as a way to provide a pollyfill for it.
Describe alternatives you've considered I have considered looking for other alternatives to google-spreadsheet in the Deno third-party modules but I was not lucky enough to find one.
std/node
has a basic support of https
module (At least https.request and https.get are available). I think the above is an issue of skypack's side.
BTW google-spreadsheet module seems available & importable with esm.sh
. How about trying that version?
The below ran successfully on my machine:
import * as a from "https://esm.sh/google-spreadsheet";
console.log(a);
std/node
has a basic support ofhttps
module (At least https.request and https.get are available). I think the above is an issue of skypack's side.BTW google-spreadsheet module seems available & importable with
esm.sh
. How about trying that version?The below ran successfully on my machine:
import * as a from "https://esm.sh/google-spreadsheet"; console.log(a);
Thank you so much for your reply, I'll try it. I just saw the message in the manual saying that it wasn't yet implemented and created the issue.