Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Remove axios dependency #16

Open
domharrington opened this issue Jun 13, 2023 · 1 comment
Open

Remove axios dependency #16

domharrington opened this issue Jun 13, 2023 · 1 comment

Comments

@domharrington
Copy link
Member

Just use fetch()?

@cvan
Copy link
Contributor

cvan commented Jun 13, 2023

  • for any GitHub API requests, octokit can be called from the already installed @actions/github package.
  • for the existing Bitbucket API, there's this npm package bitbucket, which is a pretty nice octokit-esque Node client.

tl;dr: it's probably safe to just use plain old fetch. or, if folks are stuck running versions of node earlier than v18 (~v17.5 added fetch), GitHub recommends using @actions/http-client.

paranoid: if build sizes & times become an issue, using Node's builtin https module to make HTTP requests would work just fine (there are quite a few examples in the @vercel, @actions, @netlify, … orgs).

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants