Ignore https-proxy-agent dependency in browser environments (#2133)

* Ignore https-proxy-agent in browsers

* ignore eslint-comments/no-unused-disable linting rule
This commit is contained in:
mpint
2022-11-16 17:01:06 -06:00
committed by GitHub
parent c4c8e58fd9
commit a4c2bb998f
5 changed files with 10 additions and 3 deletions

View File

@@ -28,6 +28,10 @@ module.exports = {
plugins: [],
extends: ['@xrplf/eslint-config/base', 'plugin:mocha/recommended'],
rules: {
// Disabled until https://github.com/import-js/eslint-plugin-import/pull/2305 is resolved to
// accomodate this change https://github.com/XRPLF/xrpl.js/pull/2133
'import/no-unused-modules': 'off',
'eslint-comments/no-unused-disable': 'off',
// Certain rippled APIs require snake_case naming
'@typescript-eslint/naming-convention': [
'error',

View File

@@ -2,6 +2,10 @@
Subscribe to [the **xrpl-announce** mailing list](https://groups.google.com/g/xrpl-announce) for release announcements. We recommend that xrpl.js (ripple-lib) users stay up-to-date with the latest stable release.
## Unreleased
### Fixed
* Ignore `https-proxy-agent` in browsers for improved Vite integration
### Added
* Optional custom amount field to `fundWallet`.

View File

@@ -18,7 +18,8 @@
"test": "test"
},
"browser": {
"ws": "./dist/npm/client/WSWrapper.js"
"ws": "./dist/npm/client/WSWrapper.js",
"https-proxy-agent": false
},
"dependencies": {
"bignumber.js": "^9.0.0",

View File

@@ -1,4 +1,3 @@
/* eslint-disable import/no-unused-modules -- Used by webpack */
/* eslint-disable max-classes-per-file -- Needs to be a wrapper for ws */
import { EventEmitter } from 'events'

View File

@@ -136,7 +136,6 @@ export interface LedgerStream extends BaseStream {
/**
* This response mirrors the LedgerStream, except it does NOT include the 'type' nor 'txn_count' fields.
*/
// eslint-disable-next-line import/no-unused-modules -- Detailed enough to be worth exporting for end users.
export interface LedgerStreamResponse {
/**
* The reference transaction cost as of this ledger version, in drops of XRP.