chore: add xhr2 package

This commit is contained in:
im-adithya 2024-12-19 16:15:21 +05:30
parent 262a41bb96
commit c0fff3b95a
4 changed files with 18 additions and 2 deletions

2
.gitignore vendored

@ -26,3 +26,5 @@ yarn-error.log*
# generated code
/src/protobuf/**
dist

12
package-lock.json generated

@ -12,7 +12,8 @@
"@types/node": "^18.14.2",
"console": "^0.7.2",
"google-protobuf": "^3.20.3",
"grpc-web": "^1.4.2"
"grpc-web": "^1.4.2",
"xhr2": "^0.2.1"
},
"devDependencies": {
"@babel/core": "^7.21.0",
@ -9867,6 +9868,15 @@
"node": "^12.13.0 || ^14.15.0 || >=16.0.0"
}
},
"node_modules/xhr2": {
"version": "0.2.1",
"resolved": "https://registry.npmjs.org/xhr2/-/xhr2-0.2.1.tgz",
"integrity": "sha512-sID0rrVCqkVNUn8t6xuv9+6FViXjUVXq8H5rWOH2rz9fDNQEd4g0EA2XlcEdJXRz5BMEn4O1pJFdT+z4YHhoWw==",
"license": "MIT",
"engines": {
"node": ">= 6"
}
},
"node_modules/y18n": {
"version": "5.0.8",
"resolved": "https://registry.npmjs.org/y18n/-/y18n-5.0.8.tgz",

@ -31,7 +31,8 @@
"console": "^0.7.2",
"decimal.js": "^10.4.3",
"google-protobuf": "^3.20.3",
"grpc-web": "^1.4.2"
"grpc-web": "^1.4.2",
"xhr2": "^0.2.1"
},
"devDependencies": {
"@babel/core": "^7.21.0",

@ -1,3 +1,6 @@
import XMLHttpRequest from "xhr2";
global.XMLHttpRequest = XMLHttpRequest;
import HavenoClient from "./HavenoClient";
import HavenoError from "./types/HavenoError";
import HavenoUtils from "./utils/HavenoUtils";