googleapis / googleapis/google-cloud-node
Support edge runtime
- Dominant language
- TypeScript
- Stars
- 3.2k
- Forks
- 712
- Avg merge
- 2d 3h
- Merged PRs (30d)
- 99
Description
Currently this library depends on NodeJS runtime libraries, so it won't work on the edge using edge runtime such as Vercel edge functions or CloudFlare workers (for example using Next.js).
It would be great if this could be supported. The only caveat is that other library loggers would have to support it as well.
Right now I'm getting this error when using a Next.js route which uses the 'edge' runtime:
```
○ Compiling /discover ...
⨯ ./node_modules/.pnpm/@google-cloud+common@5.0.2/node_modules/@google-cloud/common/build/src/util.js:25:1
Module not found: Can't resolve 'stream'
https://nextjs.org/docs/messages/module-not-found
Import trace for requested module:
./node_modules/.pnpm/@google-cloud+common@5.0.2/node_modules/@google-cloud/common/build/src/index.js
./node_modules/.pnpm/@google-cloud+logging@11.2.0/node_modules/@google-cloud/logging/build/src/index.js
./lib/logger/log.ts
```
Contributor guide
Assessment
This issue has not been assessed yet.