From b826038df0bc7c1e5e1a2275205c5658a7b3f747 Mon Sep 17 00:00:00 2001 From: Paul Date: Fri, 24 Dec 2021 23:01:03 +0000 Subject: [PATCH] chore: force custom packages + add notice --- README.md | 4 ++++ package.json | 6 +++--- src/config.ts | 2 +- src/websocket/client.ts | 4 ++-- yarn.lock | 20 ++++++++++---------- 5 files changed, 20 insertions(+), 16 deletions(-) diff --git a/README.md b/README.md index 2ce011a0..8cfb9192 100644 --- a/README.md +++ b/README.md @@ -24,6 +24,10 @@ client.on("message", async (message) => { client.loginBot(".."); ``` +If you are using Node, you must specify `--experimental-specifier-resolution=node`. + +For example, `node --experimental-specifier-resolution=node index.js`. + ## MobX MobX is used behind the scenes so you can subscribe to any change as you normally would, e.g. with `mobx-react(-lite)` or mobx's utility functions. diff --git a/package.json b/package.json index e1aae67d..7d10fd59 100644 --- a/package.json +++ b/package.json @@ -1,16 +1,16 @@ { "type": "module", "name": "revolt.js", - "version": "5.2.1-patch.2", + "version": "5.2.1-patch.3", "main": "dist/index.js", "repository": "https://github.com/revoltchat/revolt.js", "author": "Paul Makles ", "license": "MIT", "dependencies": { + "@insertish/exponential-backoff": "^3.1.0", + "@insertish/isomorphic-ws": "^4.0.1", "axios": "^0.21.4", "eventemitter3": "^4.0.7", - "exponential-backoff": "npm:@insertish/exponential-backoff", - "isomorphic-ws": "npm:@insertish/isomorphic-ws", "lodash.defaultsdeep": "^4.6.1", "lodash.flatten": "^4.4.0", "lodash.isequal": "^4.5.0", diff --git a/src/config.ts b/src/config.ts index 6d83d191..04ffaeb2 100644 --- a/src/config.ts +++ b/src/config.ts @@ -1,4 +1,4 @@ -export const LIBRARY_VERSION = "5.2.1-patch.2"; +export const LIBRARY_VERSION = "5.2.1-patch.3"; export const defaultConfig = { apiURL: "https://api.revolt.chat", diff --git a/src/websocket/client.ts b/src/websocket/client.ts index b69021c2..efe6f31d 100644 --- a/src/websocket/client.ts +++ b/src/websocket/client.ts @@ -1,5 +1,5 @@ -import { backOff } from "exponential-backoff"; -import WebSocket from "isomorphic-ws"; +import { backOff } from "@insertish/exponential-backoff"; +import WebSocket from "@insertish/isomorphic-ws"; import { runInAction } from "mobx"; import { Role } from "revolt-api/types/Servers"; diff --git a/yarn.lock b/yarn.lock index 09bb7820..36247b64 100644 --- a/yarn.lock +++ b/yarn.lock @@ -31,6 +31,16 @@ resolved "https://registry.yarnpkg.com/@humanwhocodes/object-schema/-/object-schema-1.2.1.tgz#b520529ec21d8e5945a1851dfd1c32e94e39ff45" integrity sha512-ZnQMnLV4e7hDlUvw8H+U8ASL02SS2Gn6+9Ac3wGGLIe7+je2AeAOxPY+izIPJDfFDb7eDjev0Us8MO1iFRN8hA== +"@insertish/exponential-backoff@^3.1.0": + version "3.1.0" + resolved "https://registry.yarnpkg.com/@insertish/exponential-backoff/-/exponential-backoff-3.1.0.tgz#1d2e4c215fa8647779cfeab74ecb54a5c36835e6" + integrity sha512-8Jab9OfjheI84T04QjUwXceSO1DMGy8goDqVdnuoffC2fg23zBnikLJkrRHiT/ao4c08v4R2mU7+/DXMWmROng== + +"@insertish/isomorphic-ws@^4.0.1": + version "4.0.1" + resolved "https://registry.yarnpkg.com/@insertish/isomorphic-ws/-/isomorphic-ws-4.0.1.tgz#5bcd6f73b93efa9ccdb6abf887ae808d40827169" + integrity sha512-kFD/p8T4Hkqr992QrdkbW/cQ/W/q2d9MPCobwzBv2PwTKLkCD9RaYDy6m17qRnSLQQ5PU0kHCG8kaOwAqzj1vQ== + "@nodelib/fs.scandir@2.1.5": version "2.1.5" resolved "https://registry.yarnpkg.com/@nodelib/fs.scandir/-/fs.scandir-2.1.5.tgz#7619c2eb21b25483f6d167548b4cfd5a7488c3d5" @@ -1008,11 +1018,6 @@ expand-tilde@^2.0.0, expand-tilde@^2.0.2: dependencies: homedir-polyfill "^1.0.1" -"exponential-backoff@npm:@insertish/exponential-backoff": - version "3.1.0" - resolved "https://registry.yarnpkg.com/@insertish/exponential-backoff/-/exponential-backoff-3.1.0.tgz#1d2e4c215fa8647779cfeab74ecb54a5c36835e6" - integrity sha512-8Jab9OfjheI84T04QjUwXceSO1DMGy8goDqVdnuoffC2fg23zBnikLJkrRHiT/ao4c08v4R2mU7+/DXMWmROng== - ext@^1.1.2: version "1.4.0" resolved "https://registry.yarnpkg.com/ext/-/ext-1.4.0.tgz#89ae7a07158f79d35517882904324077e4379244" @@ -1789,11 +1794,6 @@ isobject@^3.0.0, isobject@^3.0.1: resolved "https://registry.yarnpkg.com/isobject/-/isobject-3.0.1.tgz#4e431e92b11a9731636aa1f9c8d1ccbcfdab78df" integrity sha1-TkMekrEalzFjaqH5yNHMvP2reN8= -"isomorphic-ws@npm:@insertish/isomorphic-ws": - version "4.0.1" - resolved "https://registry.yarnpkg.com/@insertish/isomorphic-ws/-/isomorphic-ws-4.0.1.tgz#5bcd6f73b93efa9ccdb6abf887ae808d40827169" - integrity sha512-kFD/p8T4Hkqr992QrdkbW/cQ/W/q2d9MPCobwzBv2PwTKLkCD9RaYDy6m17qRnSLQQ5PU0kHCG8kaOwAqzj1vQ== - js-yaml@^4.1.0: version "4.1.0" resolved "https://registry.yarnpkg.com/js-yaml/-/js-yaml-4.1.0.tgz#c1fb65f8f5017901cdd2c951864ba18458a10602"