Replace deprecated HTTP request library with modern standard. Proxy support.
The primary goal was to transition to axios, since the npm module request is both deprecated and carries a ton of dependency baggage. This version does not change any high level functionality, ensuring no integration changes are required to upgrade to this release.
Difference in dependency baggage
As well as a smaller memory footprint, an additional bonus of this adoption of axios
is support for proxied requests as well as other customizations to how HTTP requests are made by the library. See the axios request config for a detailed list of options.
Action Required to Upgrade
None
Summary
- replace the deprecated npm request module with the much lighter axios module. Resolves #4.
- huge reduction in module footprint (see step to 1.2.0): https://bundlephobia.com/result?p=bybit-api@1.2.0
- expose request options in constructor, allowing proxy support (among other settings)
- bump websocket connectivity dependency to latest version.
- validated #12 is not an issue.
- misc refactoring & cleaning.