diff --git a/.eslintrc.json b/.eslintrc.json index 4db51ca..45ef023 100644 --- a/.eslintrc.json +++ b/.eslintrc.json @@ -1,19 +1,9 @@ { "env": { - "es6": true, + "es2022": true, "node": true }, "extends": "eslint:recommended", - "globals": { - "Atomics": "readable", - "BigInt": "readable", - "BigInt64Array": "readable", - "BigUint64Array": "readable", - "queueMicrotask": "readable", - "SharedArrayBuffer": "readable", - "TextEncoder": "readable", - "TextDecoder": "readable" - }, "overrides": [ { "files": ["*.mjs"], @@ -39,13 +29,13 @@ }, "rules": { "max-len": "off", - "prefer-arrow-callback": "off" + "prefer-arrow-callback": "off", + "no-return-assign": "off" } } ], - "parser": "babel-eslint", "parserOptions": { - "ecmaVersion": 10, + "ecmaVersion": 13, "ecmaFeatures": { "globalReturn": true }, diff --git a/lib/key.js b/lib/key.js index 6fb7dda..d1b6fc3 100644 --- a/lib/key.js +++ b/lib/key.js @@ -343,6 +343,7 @@ class BaseKey { assert(typeof name === 'string'); + // eslint-disable-next-line no-prototype-builtins if (!types.hasOwnProperty(name)) throw new Error(`Invalid type name: ${name}.`); diff --git a/lib/rbt.js b/lib/rbt.js index 61332fa..436c14e 100644 --- a/lib/rbt.js +++ b/lib/rbt.js @@ -759,24 +759,6 @@ class RBTIterator { */ class RBTNode { - /** @type {Buffer} */ - key; - - /** @type {Buffer} */ - value; - - /** @type {Number} */ - color; - - /** @type {RBTNode|RBTSentinel} */ - parent; - - /** @type {RBTNode|RBTSentinel} */ - left; - - /** @type {RBTNode|RBTSentinel} */ - right; - /** * Create an RBT node. * @constructor @@ -849,24 +831,6 @@ class RBTNode { */ class RBTSentinel { - /** @type {null} */ - key; - - /** @type {null} */ - value; - - /** @type {Number} */ - color; - - /** @type {null} */ - parent; - - /** @type {null} */ - left; - - /** @type {null} */ - right; - /** * Create an RBT Sentinel Node. * @constructor