bitski-provider
Advanced tools
Comparing version 2.0.0-beta.9 to 2.0.0-beta.10
# bitski-provider | ||
## 2.0.0-beta.10 | ||
### Minor Changes | ||
- [#324](https://github.com/BitskiCo/bitski-js/pull/324) [`0d48684`](https://github.com/BitskiCo/bitski-js/commit/0d48684839f0850380bdce1f645320fdfa830ace) Thanks [@chronicIntrovert](https://github.com/chronicIntrovert)! - Add Arbitrum and Optimism to list of chain types | ||
## 2.0.0-beta.9 | ||
@@ -4,0 +10,0 @@ |
@@ -43,3 +43,3 @@ import SafeEventEmitter from '@metamask/safe-event-emitter'; | ||
this.activeSubs = new Set(); | ||
this.config = Object.assign(Object.assign({}, config), { fetch: (_a = config.fetch) !== null && _a !== void 0 ? _a : fetch, additionalHeaders: Object.assign({ 'X-API-KEY': config.clientId, 'X-CLIENT-ID': config.clientId, 'X-CLIENT-VERSION': "bitski-provider-v2.0.0-beta.9" }, ((_b = config.additionalHeaders) !== null && _b !== void 0 ? _b : {})), apiBaseUrl: (_c = config.apiBaseUrl) !== null && _c !== void 0 ? _c : BITSKI_API_BASE_URL, signerBaseUrl: (_d = config.signerBaseUrl) !== null && _d !== void 0 ? _d : BITSKI_SIGNER_BASE_URL, store: (_e = config.store) !== null && _e !== void 0 ? _e : new LocalStorageStore(), sign: (_f = config.sign) !== null && _f !== void 0 ? _f : createBrowserSigner() }); | ||
this.config = Object.assign(Object.assign({}, config), { fetch: (_a = config.fetch) !== null && _a !== void 0 ? _a : fetch, additionalHeaders: Object.assign({ 'X-API-KEY': config.clientId, 'X-CLIENT-ID': config.clientId, 'X-CLIENT-VERSION': "bitski-provider-v2.0.0-beta.10" }, ((_b = config.additionalHeaders) !== null && _b !== void 0 ? _b : {})), apiBaseUrl: (_c = config.apiBaseUrl) !== null && _c !== void 0 ? _c : BITSKI_API_BASE_URL, signerBaseUrl: (_d = config.signerBaseUrl) !== null && _d !== void 0 ? _d : BITSKI_SIGNER_BASE_URL, store: (_e = config.store) !== null && _e !== void 0 ? _e : new LocalStorageStore(), sign: (_f = config.sign) !== null && _f !== void 0 ? _f : createBrowserSigner() }); | ||
this.store = new BitskiProviderStateStore(this.config.store); | ||
@@ -46,0 +46,0 @@ // Setup the engine |
@@ -81,2 +81,4 @@ import { EthMethod } from 'eth-provider-types'; | ||
export const Mumbai = makeChainDef(80001, 'Mumbai', 'https://mumbai.polygonscan.com/'); | ||
export const Arbitrum = makeChainDef(42161, 'Arbitrum', 'https://arbiscan.io/'); | ||
export const Optimism = makeChainDef(10, 'Optimism', 'https://optimistic.etherscan.io/'); | ||
export const BinanceSmartChain = makeChainDef(56, 'BinanceSmartChain', 'https://bscscan.com/'); | ||
@@ -83,0 +85,0 @@ export const BinanceSmartChainTestnet = makeChainDef(97, 'BinanceSmartChainTestnet', 'https://testnet.bscscan.com/'); |
@@ -49,3 +49,3 @@ "use strict"; | ||
this.activeSubs = new Set(); | ||
this.config = Object.assign(Object.assign({}, config), { fetch: (_a = config.fetch) !== null && _a !== void 0 ? _a : fetch, additionalHeaders: Object.assign({ 'X-API-KEY': config.clientId, 'X-CLIENT-ID': config.clientId, 'X-CLIENT-VERSION': "bitski-provider-v2.0.0-beta.9" }, ((_b = config.additionalHeaders) !== null && _b !== void 0 ? _b : {})), apiBaseUrl: (_c = config.apiBaseUrl) !== null && _c !== void 0 ? _c : constants_1.BITSKI_API_BASE_URL, signerBaseUrl: (_d = config.signerBaseUrl) !== null && _d !== void 0 ? _d : constants_1.BITSKI_SIGNER_BASE_URL, store: (_e = config.store) !== null && _e !== void 0 ? _e : new store_1.LocalStorageStore(), sign: (_f = config.sign) !== null && _f !== void 0 ? _f : (0, browser_1.default)() }); | ||
this.config = Object.assign(Object.assign({}, config), { fetch: (_a = config.fetch) !== null && _a !== void 0 ? _a : fetch, additionalHeaders: Object.assign({ 'X-API-KEY': config.clientId, 'X-CLIENT-ID': config.clientId, 'X-CLIENT-VERSION': "bitski-provider-v2.0.0-beta.10" }, ((_b = config.additionalHeaders) !== null && _b !== void 0 ? _b : {})), apiBaseUrl: (_c = config.apiBaseUrl) !== null && _c !== void 0 ? _c : constants_1.BITSKI_API_BASE_URL, signerBaseUrl: (_d = config.signerBaseUrl) !== null && _d !== void 0 ? _d : constants_1.BITSKI_SIGNER_BASE_URL, store: (_e = config.store) !== null && _e !== void 0 ? _e : new store_1.LocalStorageStore(), sign: (_f = config.sign) !== null && _f !== void 0 ? _f : (0, browser_1.default)() }); | ||
this.store = new store_1.BitskiProviderStateStore(this.config.store); | ||
@@ -52,0 +52,0 @@ // Setup the engine |
@@ -15,4 +15,6 @@ import { EthChainDefinitionWithRpcUrl } from './types'; | ||
export declare const Mumbai: EthChainDefinitionWithRpcUrl; | ||
export declare const Arbitrum: EthChainDefinitionWithRpcUrl; | ||
export declare const Optimism: EthChainDefinitionWithRpcUrl; | ||
export declare const BinanceSmartChain: EthChainDefinitionWithRpcUrl; | ||
export declare const BinanceSmartChainTestnet: EthChainDefinitionWithRpcUrl; | ||
export declare const DEFAULT_CHAINS: EthChainDefinitionWithRpcUrl[]; |
"use strict"; | ||
Object.defineProperty(exports, "__esModule", { value: true }); | ||
exports.DEFAULT_CHAINS = exports.BinanceSmartChainTestnet = exports.BinanceSmartChain = exports.Mumbai = exports.Polygon = exports.Goerli = exports.Mainnet = exports.SUPPORTED_CHAIN_IDS = exports.UNAUTHORIZED_ERRORS = exports.RETRIABLE_ERRORS = exports.AUTHENTICATED_METHODS = exports.SIGN_METHODS = exports.IFRAME_MESSAGE_ORIGIN_ENDS_WITH = exports.BITSKI_SIGNER_BASE_URL = exports.BITSKI_RPC_BASE_URL = exports.BITSKI_API_BASE_URL = void 0; | ||
exports.DEFAULT_CHAINS = exports.BinanceSmartChainTestnet = exports.BinanceSmartChain = exports.Optimism = exports.Arbitrum = exports.Mumbai = exports.Polygon = exports.Goerli = exports.Mainnet = exports.SUPPORTED_CHAIN_IDS = exports.UNAUTHORIZED_ERRORS = exports.RETRIABLE_ERRORS = exports.AUTHENTICATED_METHODS = exports.SIGN_METHODS = exports.IFRAME_MESSAGE_ORIGIN_ENDS_WITH = exports.BITSKI_SIGNER_BASE_URL = exports.BITSKI_RPC_BASE_URL = exports.BITSKI_API_BASE_URL = void 0; | ||
const eth_provider_types_1 = require("eth-provider-types"); | ||
@@ -84,2 +84,4 @@ const parse_utils_1 = require("./utils/parse-utils"); | ||
exports.Mumbai = makeChainDef(80001, 'Mumbai', 'https://mumbai.polygonscan.com/'); | ||
exports.Arbitrum = makeChainDef(42161, 'Arbitrum', 'https://arbiscan.io/'); | ||
exports.Optimism = makeChainDef(10, 'Optimism', 'https://optimistic.etherscan.io/'); | ||
exports.BinanceSmartChain = makeChainDef(56, 'BinanceSmartChain', 'https://bscscan.com/'); | ||
@@ -86,0 +88,0 @@ exports.BinanceSmartChainTestnet = makeChainDef(97, 'BinanceSmartChainTestnet', 'https://testnet.bscscan.com/'); |
@@ -12,3 +12,3 @@ { | ||
}, | ||
"version": "2.0.0-beta.9", | ||
"version": "2.0.0-beta.10", | ||
"scripts": { | ||
@@ -15,0 +15,0 @@ "test": "jest", |
import { EthMethod } from 'eth-provider-types'; | ||
import { EthChainDefinitionWithRpcUrl } from './types'; | ||
@@ -95,2 +96,4 @@ import { toHex } from './utils/parse-utils'; | ||
export const Mumbai = makeChainDef(80001, 'Mumbai', 'https://mumbai.polygonscan.com/'); | ||
export const Arbitrum = makeChainDef(42161, 'Arbitrum', 'https://arbiscan.io/'); | ||
export const Optimism = makeChainDef(10, 'Optimism', 'https://optimistic.etherscan.io/'); | ||
export const BinanceSmartChain = makeChainDef(56, 'BinanceSmartChain', 'https://bscscan.com/'); | ||
@@ -97,0 +100,0 @@ export const BinanceSmartChainTestnet = makeChainDef( |
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
355326
7621