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

Several improvements and fixes #5

Open
wants to merge 7 commits into
base: main
Choose a base branch
from

Conversation

remorses
Copy link

@remorses remorses commented Apr 20, 2023

What is this?

  1. Replced axios with native-fetch so this package can be used in Cloudflare workers and non Node.js runtimes
  2. Moved package out of module folder
  3. Throw errors instead of strings, closes sdk should throw errors instead of strings #4
  4. Removed use of the type object, as object is basically an alias for any, while you intended to refer to a "dict": https://www.typescripttutorial.net/typescript-tutorial/typescript-object-type/
  5. Use BananaError for errors and make the original banana response accessible
  6. Removed unused dependencies
  7. Increased version number

Why?

Makes DX much better, allows you to use this package in Cloudflare workers, Vercel edge, etc

How did you test to ensure no regressions?

Tested on my own project

If this is a new feature what is one way you can make this break?

It is not a breaking change, same behaviour as before

@remorses remorses marked this pull request as ready for review April 20, 2023 15:46
@SuperEgo-Health
Copy link

SuperEgo-Health commented Aug 5, 2023

@remorses is your fork compatible with their V2 API?

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

Successfully merging this pull request may close these issues.

sdk should throw errors instead of strings
2 participants