├── examples ├── pre-ts-4.5 │ ├── .vscode │ │ └── settings.json │ ├── index.ts │ ├── package.json │ └── pnpm-lock.yaml ├── negative.js ├── scrub.js ├── try-esm │ ├── index.js │ ├── package.json │ └── pnpm-lock.yaml ├── try │ ├── index.js │ ├── package.json │ └── pnpm-lock.yaml ├── leaves.cjs ├── json.js └── stringify.js ├── .gitignore ├── src ├── legacy.cts ├── modern.ts └── index.ts ├── vitest.config.ts ├── .changeset ├── config.json └── README.md ├── .prettierrc ├── test ├── tsconfig.json ├── obj.test.ts ├── typed-array.test.ts ├── error.test.ts ├── leaves.test.ts ├── instance.test.ts ├── negative.test.ts ├── keys.test.ts ├── subexpr.test.ts ├── date.test.ts ├── interface.test.ts ├── json.test.ts ├── stringify.test.ts ├── siblings.test.ts ├── stop.test.ts ├── has.test.ts ├── circular.test.ts └── mutability.test.ts ├── .github └── workflows │ ├── cr.yml │ ├── test.yml │ └── release.yml ├── tsconfig.json ├── LICENSE ├── tsup.config.ts ├── CHANGELOG.md ├── package.json ├── README.md └── pnpm-lock.yaml /examples/pre-ts-4.5/.vscode/settings.json: -------------------------------------------------------------------------------- 1 | { 2 | "typescript.tsdk": "node_modules/typescript/lib" 3 | } 4 | -------------------------------------------------------------------------------- /.gitignore: -------------------------------------------------------------------------------- 1 | # gitignore 2 | 3 | node_modules/ 4 | coverage/ 5 | 6 | .npmignore 7 | dist 8 | /legacy.js 9 | /legacy.d.ts -------------------------------------------------------------------------------- /src/legacy.cts: -------------------------------------------------------------------------------- 1 | import traverse from './index'; 2 | 3 | export { default, TraverseContext, TraverseOptions } from './index'; 4 | 5 | module.exports = traverse; 6 | -------------------------------------------------------------------------------- /examples/pre-ts-4.5/index.ts: -------------------------------------------------------------------------------- 1 | import traverse from 'neotraverse/legacy'; 2 | 3 | const obj = { a: 1, b: 2, c: [3, 4] }; 4 | 5 | traverse(obj).forEach(function (x) { 6 | if (x < 0) this.update(x + 128); 7 | }); 8 | -------------------------------------------------------------------------------- /vitest.config.ts: -------------------------------------------------------------------------------- 1 | import { defineConfig } from 'vitest/config'; 2 | 3 | export default defineConfig({ 4 | test: { 5 | coverage: { 6 | provider: 'v8', 7 | include: ['src/**/*.ts'], 8 | }, 9 | }, 10 | }); 11 | -------------------------------------------------------------------------------- /examples/negative.js: -------------------------------------------------------------------------------- 1 | 'use strict'; 2 | 3 | var traverse = require('traverse'); 4 | var obj = [5, 6, -3, [7, 8, -2, 1], { f: 10, g: -13 }]; 5 | 6 | traverse(obj).forEach(function (x) { 7 | if (x < 0) { this.update(x + 128); } 8 | }); 9 | 10 | console.dir(obj); 11 | -------------------------------------------------------------------------------- /examples/scrub.js: -------------------------------------------------------------------------------- 1 | 'use strict'; 2 | 3 | // scrub out circular references 4 | var traverse = require('traverse'); 5 | 6 | var obj = { a: 1, b: 2, c: [3, 4] }; 7 | obj.c.push(obj); 8 | 9 | var scrubbed = traverse(obj).map(function () { 10 | if (this.circular) { this.remove(); } 11 | }); 12 | console.dir(scrubbed); 13 | -------------------------------------------------------------------------------- /.changeset/config.json: -------------------------------------------------------------------------------- 1 | { 2 | "$schema": "https://unpkg.com/@changesets/config@3.0.2/schema.json", 3 | "changelog": "@changesets/cli/changelog", 4 | "commit": false, 5 | "fixed": [], 6 | "linked": [], 7 | "access": "public", 8 | "baseBranch": "main", 9 | "updateInternalDependencies": "patch", 10 | "ignore": [] 11 | } 12 | -------------------------------------------------------------------------------- /examples/try-esm/index.js: -------------------------------------------------------------------------------- 1 | import traverse from 'neotraverse/legacy'; 2 | 3 | const obj = { 4 | a: 1, 5 | b: 2, 6 | c: { 7 | d: 3, 8 | e: 4, 9 | f: { 10 | g: 5, 11 | h: 6, 12 | }, 13 | }, 14 | }; 15 | 16 | traverse(obj).forEach(function (node) { 17 | if (node === 6) this.update(68); 18 | }); 19 | 20 | console.log(obj); 21 | -------------------------------------------------------------------------------- /examples/try/index.js: -------------------------------------------------------------------------------- 1 | const traverse = /** @type {import('neotraverse/legacy')['default']} */ ( 2 | require('neotraverse/legacy') 3 | ); 4 | 5 | const obj = { 6 | a: 1, 7 | b: 2, 8 | c: { 9 | d: 3, 10 | e: 4, 11 | f: { 12 | g: 5, 13 | h: 6, 14 | }, 15 | }, 16 | }; 17 | 18 | traverse(obj).forEach((node) => {}); 19 | 20 | console.log(obj); 21 | -------------------------------------------------------------------------------- /examples/try/package.json: -------------------------------------------------------------------------------- 1 | { 2 | "name": "try", 3 | "version": "1.0.0", 4 | "main": "index.js", 5 | "scripts": { 6 | "test": "echo \"Error: no test specified\" && exit 1" 7 | }, 8 | "keywords": [], 9 | "author": "", 10 | "license": "ISC", 11 | "description": "", 12 | "dependencies": { 13 | "neotraverse": "https://pkg.pr.new/PuruVJ/neotraverse@10" 14 | } 15 | } 16 | -------------------------------------------------------------------------------- /.prettierrc: -------------------------------------------------------------------------------- 1 | { 2 | "useTabs": true, 3 | "printWidth": 100, 4 | "tabWidth": 2, 5 | "singleQuote": true, 6 | "trailingComma": "all", 7 | "semi": true, 8 | "arrowParens": "always", 9 | "overrides": [ 10 | { 11 | "files": "*.md", 12 | "options": { 13 | "tabWidth": 2, 14 | "useTabs": false, 15 | "trailingComma": "none", 16 | "proseWrap": "never" 17 | } 18 | } 19 | ] 20 | } 21 | -------------------------------------------------------------------------------- /examples/try-esm/package.json: -------------------------------------------------------------------------------- 1 | { 2 | "name": "try-esm", 3 | "version": "1.0.0", 4 | "main": "index.js", 5 | "type": "module", 6 | "scripts": { 7 | "test": "echo \"Error: no test specified\" && exit 1" 8 | }, 9 | "keywords": [], 10 | "author": "", 11 | "license": "ISC", 12 | "description": "", 13 | "dependencies": { 14 | "neotraverse": "https://pkg.pr.new/PuruVJ/neotraverse@10" 15 | } 16 | } 17 | -------------------------------------------------------------------------------- /examples/leaves.cjs: -------------------------------------------------------------------------------- 1 | 'use strict'; 2 | 3 | var traverse = require('../dist/legacy/legacy.cjs'); 4 | 5 | var obj = { 6 | a: [1, 2, 3], 7 | b: 4, 8 | c: [5, 6], 9 | d: { e: [7, 8], f: 9 }, 10 | }; 11 | 12 | console.log(traverse); 13 | 14 | var leaves = traverse(obj).reduce(function (acc, x) { 15 | if (this.isLeaf) { 16 | acc.push(x); 17 | } 18 | return acc; 19 | }, []); 20 | 21 | console.dir(leaves); 22 | -------------------------------------------------------------------------------- /examples/json.js: -------------------------------------------------------------------------------- 1 | import traverse from '../dist/legacy/index.js'; 2 | 3 | var id = 54; 4 | var callbacks = {}; 5 | var obj = { moo: function () {}, foo: [2, 3, 4, function () {}] }; 6 | 7 | var scrubbed = traverse.map(obj, function (x) { 8 | if (typeof x === 'function') { 9 | callbacks[id] = { id: id, f: x, path: this.path }; 10 | this.update('[Function]'); 11 | id++; 12 | } 13 | }); 14 | 15 | console.dir(scrubbed); 16 | console.dir(callbacks); 17 | -------------------------------------------------------------------------------- /examples/pre-ts-4.5/package.json: -------------------------------------------------------------------------------- 1 | { 2 | "name": "pre-ts-4.5", 3 | "version": "1.0.0", 4 | "private": true, 5 | "main": "index.js", 6 | "type": "module", 7 | "scripts": { 8 | "test": "echo \"Error: no test specified\" && exit 1" 9 | }, 10 | "keywords": [], 11 | "author": "", 12 | "license": "ISC", 13 | "description": "", 14 | "dependencies": { 15 | "neotraverse": "^0.6.12" 16 | }, 17 | "devDependencies": { 18 | "typescript": "^4.3.5" 19 | } 20 | } 21 | -------------------------------------------------------------------------------- /test/tsconfig.json: -------------------------------------------------------------------------------- 1 | { 2 | "compilerOptions": { 3 | "target": "ESNext", 4 | "module": "ESNext", 5 | "moduleResolution": "Node", 6 | "allowSyntheticDefaultImports": true, 7 | "esModuleInterop": true, 8 | "verbatimModuleSyntax": true, 9 | "allowImportingTsExtensions": true, 10 | "forceConsistentCasingInFileNames": true, 11 | "strict": true, 12 | "skipLibCheck": true, 13 | "declaration": true, 14 | "emitDeclarationOnly": true, 15 | "outDir": "dist" 16 | }, 17 | "include": ["./*"] 18 | } 19 | -------------------------------------------------------------------------------- /test/obj.test.ts: -------------------------------------------------------------------------------- 1 | import { expect, test } from 'vitest'; 2 | import traverse from '../src'; 3 | import { Traverse } from '../src/modern'; 4 | 5 | test('new Traverse an object with nested functions', () => { 6 | function Cons(x: number) { 7 | expect(x).toBe(10); 8 | } 9 | // @ts-ignore 10 | traverse(new Cons(10)); 11 | }); 12 | 13 | test('new Traverse an object with nested functions_modern', () => { 14 | function Cons(x: number) { 15 | expect(x).toBe(10); 16 | } 17 | // @ts-ignore 18 | new Traverse(new Cons(10)); 19 | }); 20 | -------------------------------------------------------------------------------- /test/typed-array.test.ts: -------------------------------------------------------------------------------- 1 | import { expect, test } from 'vitest'; 2 | import traverse from '../src'; 3 | import { Traverse } from '../src/modern'; 4 | 5 | test('new Traverse an Uint8Array', () => { 6 | const obj = new Uint8Array(4); 7 | const results = traverse(obj).map(function () {}); 8 | 9 | expect(results).toEqual(obj); 10 | }); 11 | 12 | test('new Traverse an Uint8Array_modern', () => { 13 | const obj = new Uint8Array(4); 14 | const results = new Traverse(obj).map(() => {}); 15 | 16 | expect(results).toEqual(obj); 17 | }); 18 | -------------------------------------------------------------------------------- /.changeset/README.md: -------------------------------------------------------------------------------- 1 | # Changesets 2 | 3 | Hello and welcome! This folder has been automatically generated by `@changesets/cli`, a build tool that works 4 | with multi-package repos, or single-package repos to help you version and publish your code. You can 5 | find the full documentation for it [in our repository](https://github.com/changesets/changesets) 6 | 7 | We have a quick list of common questions to get you started engaging with this project in 8 | [our documentation](https://github.com/changesets/changesets/blob/main/docs/common-questions.md) 9 | -------------------------------------------------------------------------------- /.github/workflows/cr.yml: -------------------------------------------------------------------------------- 1 | name: Continuous Releases 2 | 3 | on: [push, pull_request] 4 | 5 | jobs: 6 | test: 7 | runs-on: ubuntu-latest 8 | 9 | steps: 10 | - uses: actions/checkout@v4 11 | - uses: actions/setup-node@v4 12 | with: 13 | node-version: 18 14 | 15 | - uses: pnpm/action-setup@v4 16 | with: 17 | version: 9 18 | run_install: true 19 | 20 | - name: Compile 21 | run: pnpm compile 22 | 23 | - name: Release 24 | run: pnpm dlx pkg-pr-new publish 25 | -------------------------------------------------------------------------------- /tsconfig.json: -------------------------------------------------------------------------------- 1 | { 2 | "compilerOptions": { 3 | "target": "ESNext", 4 | "module": "ESNext", 5 | "moduleResolution": "Bundler", 6 | "allowSyntheticDefaultImports": true, 7 | "esModuleInterop": true, 8 | // Do not reenable this, breaks types for pre-4.5 TS 9 | // "verbatimModuleSyntax": true, 10 | "allowImportingTsExtensions": true, 11 | "forceConsistentCasingInFileNames": true, 12 | "strict": true, 13 | "skipLibCheck": true, 14 | "declaration": true, 15 | "emitDeclarationOnly": true, 16 | "outDir": "dist" 17 | }, 18 | "include": ["src"] 19 | } 20 | -------------------------------------------------------------------------------- /.github/workflows/test.yml: -------------------------------------------------------------------------------- 1 | name: Test 2 | 3 | on: [push, pull_request] 4 | 5 | jobs: 6 | test: 7 | runs-on: ubuntu-latest 8 | 9 | strategy: 10 | matrix: 11 | node-version: ['18.x', '20.x', '22.x'] 12 | 13 | steps: 14 | - uses: actions/checkout@v4 15 | - uses: actions/setup-node@v4 16 | with: 17 | node-version: ${{ matrix.node-version }} 18 | 19 | - uses: pnpm/action-setup@v4 20 | with: 21 | version: 9 22 | run_install: true 23 | 24 | - name: Test 25 | run: pnpm test:cov 26 | -------------------------------------------------------------------------------- /test/error.test.ts: -------------------------------------------------------------------------------- 1 | import { expect, test } from 'vitest'; 2 | import traverse from '../src'; 3 | import { Traverse } from '../src/modern'; 4 | 5 | test('error', () => { 6 | const obj = new Error('test'); 7 | const results = traverse(obj).map(function () {}); 8 | // t.same(results, { message: 'test' }); 9 | expect(results).toEqual({ message: 'test' }); 10 | }); 11 | 12 | test('error_modern', () => { 13 | const obj = new Error('test'); 14 | const results = new Traverse(obj).map(() => {}); 15 | // t.same(results, { message: 'test' }); 16 | expect(results).toEqual({ message: 'test' }); 17 | }); 18 | -------------------------------------------------------------------------------- /examples/try/pnpm-lock.yaml: -------------------------------------------------------------------------------- 1 | lockfileVersion: '9.0' 2 | 3 | settings: 4 | autoInstallPeers: true 5 | excludeLinksFromLockfile: false 6 | 7 | importers: 8 | 9 | .: 10 | dependencies: 11 | neotraverse: 12 | specifier: https://pkg.pr.new/PuruVJ/neotraverse@10 13 | version: https://pkg.pr.new/PuruVJ/neotraverse@10 14 | 15 | packages: 16 | 17 | neotraverse@https://pkg.pr.new/PuruVJ/neotraverse@10: 18 | resolution: {tarball: https://pkg.pr.new/PuruVJ/neotraverse@10} 19 | version: 0.6.13 20 | engines: {node: '>= 18'} 21 | 22 | snapshots: 23 | 24 | neotraverse@https://pkg.pr.new/PuruVJ/neotraverse@10: {} 25 | -------------------------------------------------------------------------------- /examples/try-esm/pnpm-lock.yaml: -------------------------------------------------------------------------------- 1 | lockfileVersion: '9.0' 2 | 3 | settings: 4 | autoInstallPeers: true 5 | excludeLinksFromLockfile: false 6 | 7 | importers: 8 | 9 | .: 10 | dependencies: 11 | neotraverse: 12 | specifier: https://pkg.pr.new/PuruVJ/neotraverse@10 13 | version: https://pkg.pr.new/PuruVJ/neotraverse@10 14 | 15 | packages: 16 | 17 | neotraverse@https://pkg.pr.new/PuruVJ/neotraverse@10: 18 | resolution: {tarball: https://pkg.pr.new/PuruVJ/neotraverse@10} 19 | version: 0.6.13 20 | engines: {node: '>= 18'} 21 | 22 | snapshots: 23 | 24 | neotraverse@https://pkg.pr.new/PuruVJ/neotraverse@10: {} 25 | -------------------------------------------------------------------------------- /test/leaves.test.ts: -------------------------------------------------------------------------------- 1 | import { expect, test } from 'vitest'; 2 | import traverse from '../src'; 3 | import { Traverse } from '../src/modern'; 4 | 5 | test('leaves test', () => { 6 | const acc: any[] = []; 7 | 8 | traverse({ 9 | a: [1, 2, 3], 10 | b: 4, 11 | c: [5, 6], 12 | d: { e: [7, 8], f: 9 }, 13 | }).forEach(function (x) { 14 | if (this.isLeaf) { 15 | acc.push(x); 16 | } 17 | }); 18 | 19 | expect(acc.join(' ')).toBe('1 2 3 4 5 6 7 8 9'); 20 | }); 21 | 22 | test('leaves test_modern', () => { 23 | const acc: any[] = []; 24 | 25 | new Traverse({ 26 | a: [1, 2, 3], 27 | b: 4, 28 | c: [5, 6], 29 | d: { e: [7, 8], f: 9 }, 30 | }).forEach((ctx, x) => { 31 | if (ctx.isLeaf) { 32 | acc.push(x); 33 | } 34 | }); 35 | 36 | expect(acc.join(' ')).toBe('1 2 3 4 5 6 7 8 9'); 37 | }); 38 | -------------------------------------------------------------------------------- /test/instance.test.ts: -------------------------------------------------------------------------------- 1 | import { test, expect } from 'vitest'; 2 | import traverse from '../src'; 3 | import { Traverse } from '../src/modern'; 4 | import { EventEmitter } from 'node:events'; 5 | 6 | test('check instanceof on node elems', () => { 7 | const counts = { emitter: 0 }; 8 | 9 | traverse([new EventEmitter(), 3, 4, { ev: new EventEmitter() }]).forEach(function (node) { 10 | if (node instanceof EventEmitter) { 11 | counts.emitter += 1; 12 | } 13 | }); 14 | expect(counts.emitter).toBe(2); 15 | }); 16 | 17 | test('check instanceof on node elems_modern', () => { 18 | const counts = { emitter: 0 }; 19 | 20 | new Traverse([new EventEmitter(), 3, 4, { ev: new EventEmitter() }]).forEach((_, node) => { 21 | if (node instanceof EventEmitter) { 22 | counts.emitter += 1; 23 | } 24 | }); 25 | expect(counts.emitter).toBe(2); 26 | }); 27 | -------------------------------------------------------------------------------- /examples/pre-ts-4.5/pnpm-lock.yaml: -------------------------------------------------------------------------------- 1 | lockfileVersion: '9.0' 2 | 3 | settings: 4 | autoInstallPeers: true 5 | excludeLinksFromLockfile: false 6 | 7 | importers: 8 | 9 | .: 10 | dependencies: 11 | neotraverse: 12 | specifier: ^0.6.12 13 | version: 0.6.12 14 | devDependencies: 15 | typescript: 16 | specifier: ^4.3.5 17 | version: 4.3.5 18 | 19 | packages: 20 | 21 | neotraverse@0.6.12: 22 | resolution: {integrity: sha512-2+SB0CsPOjEs6f6PZ7ysDKANjn/jLPfJq65QWMQbEDPQWj/S/BzPkePhCDQRU5mmVquIl7FUt88DaCKGjfbZ3g==} 23 | engines: {node: '>= 18'} 24 | 25 | typescript@4.3.5: 26 | resolution: {integrity: sha512-DqQgihaQ9cUrskJo9kIyW/+g0Vxsk8cDtZ52a3NGh0YNTfpUSArXSohyUGnvbPazEPLu398C0UxmKSOrPumUzA==} 27 | engines: {node: '>=4.2.0'} 28 | hasBin: true 29 | 30 | snapshots: 31 | 32 | neotraverse@0.6.12: {} 33 | 34 | typescript@4.3.5: {} 35 | -------------------------------------------------------------------------------- /.github/workflows/release.yml: -------------------------------------------------------------------------------- 1 | name: Publish 2 | on: 3 | push: 4 | branches: 5 | - 'main' 6 | 7 | concurrency: ${{ github.workflow }}-${{ github.ref }} 8 | 9 | jobs: 10 | publish: 11 | runs-on: ubuntu-latest 12 | permissions: 13 | id-token: write 14 | contents: write 15 | packages: write 16 | pull-requests: write 17 | issues: read 18 | steps: 19 | - uses: actions/checkout@v4 20 | - uses: pnpm/action-setup@v4 21 | with: 22 | version: 9.7 23 | - uses: actions/setup-node@v4 24 | with: 25 | node-version: 18.x 26 | cache: 'pnpm' 27 | 28 | - run: pnpm install --frozen-lockfile 29 | 30 | - run: pnpm compile 31 | 32 | - name: Create Release Pull Request or Publish 33 | id: changesets 34 | uses: changesets/action@v1 35 | with: 36 | publish: pnpm run ci:release 37 | env: 38 | GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} 39 | NPM_TOKEN: ${{ secrets.NPM_TOKEN }} 40 | -------------------------------------------------------------------------------- /examples/stringify.js: -------------------------------------------------------------------------------- 1 | #!/usr/bin/env node 2 | 3 | 'use strict'; 4 | 5 | var traverse = require('traverse'); 6 | 7 | var obj = ['five', 6, -3, [7, 8, -2, 1], { f: 10, g: -13 }]; 8 | 9 | var s = ''; 10 | traverse(obj).forEach(function toS(node) { 11 | if (Array.isArray(node)) { 12 | this.before(function () { s += '['; }); 13 | this.post(function (child) { 14 | if (!child.isLast) { s += ','; } 15 | }); 16 | this.after(function () { s += ']'; }); 17 | } else if (typeof node === 'object') { 18 | this.before(function () { s += '{'; }); 19 | this.pre(function (x, key) { 20 | toS(key); 21 | s += ':'; 22 | }); 23 | this.post(function (child) { 24 | if (!child.isLast) { s += ','; } 25 | }); 26 | this.after(function () { s += '}'; }); 27 | } else if (typeof node === 'string') { 28 | s += '"' + node.toString().replace(/"/g, '\\"') + '"'; 29 | } else if (typeof node === 'function') { 30 | s += 'null'; 31 | } else { 32 | s += node.toString(); 33 | } 34 | }); 35 | 36 | console.log('JSON.stringify: ' + JSON.stringify(obj)); 37 | console.log('this stringify: ' + s); 38 | -------------------------------------------------------------------------------- /LICENSE: -------------------------------------------------------------------------------- 1 | MIT License 2 | 3 | Copyright (c) 2010 James Halliday and contributors 4 | 5 | Permission is hereby granted, free of charge, to any person obtaining a copy 6 | of this software and associated documentation files (the "Software"), to deal 7 | in the Software without restriction, including without limitation the rights 8 | to use, copy, modify, merge, publish, distribute, sublicense, and/or sell 9 | copies of the Software, and to permit persons to whom the Software is 10 | furnished to do so, subject to the following conditions: 11 | 12 | The above copyright notice and this permission notice shall be included in all 13 | copies or substantial portions of the Software. 14 | 15 | THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR 16 | IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, 17 | FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE 18 | AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER 19 | LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, 20 | OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE 21 | SOFTWARE. 22 | -------------------------------------------------------------------------------- /test/negative.test.ts: -------------------------------------------------------------------------------- 1 | import { describe, expect, test } from 'vitest'; 2 | import traverse from '../src'; 3 | import { Traverse } from '../src/modern'; 4 | 5 | describe('negative update test', () => { 6 | const obj = [5, 6, -3, [7, 8, -2, 1], { f: 10, g: -13 }]; 7 | const fixed = traverse(obj).map(function (x) { 8 | if (x < 0) { 9 | this.update(x + 128); 10 | } 11 | }); 12 | 13 | test('Negative values += 128', () => { 14 | expect(fixed).toEqual([5, 6, 125, [7, 8, 126, 1], { f: 10, g: 115 }]); 15 | }); 16 | 17 | test('Original references not modified', () => { 18 | expect(obj).toEqual([5, 6, -3, [7, 8, -2, 1], { f: 10, g: -13 }]); 19 | }); 20 | }); 21 | 22 | describe('negative update test_modern', () => { 23 | const obj = [5, 6, -3, [7, 8, -2, 1], { f: 10, g: -13 }]; 24 | const fixed = new Traverse(obj).map((ctx, x) => { 25 | if (x < 0) { 26 | ctx.update(x + 128); 27 | } 28 | }); 29 | 30 | test('Negative values += 128', () => { 31 | expect(fixed).toEqual([5, 6, 125, [7, 8, 126, 1], { f: 10, g: 115 }]); 32 | }); 33 | 34 | test('Original references not modified', () => { 35 | expect(obj).toEqual([5, 6, -3, [7, 8, -2, 1], { f: 10, g: -13 }]); 36 | }); 37 | }); 38 | -------------------------------------------------------------------------------- /test/keys.test.ts: -------------------------------------------------------------------------------- 1 | import { expect, test } from 'vitest'; 2 | import traverse from '../src'; 3 | import { Traverse } from '../src/modern'; 4 | 5 | test('sort test', () => { 6 | const acc: any[] = []; 7 | 8 | traverse({ 9 | a: 30, 10 | b: 22, 11 | id: 9, 12 | }).forEach(function (node) { 13 | if (!Array.isArray(node) && typeof node === 'object') { 14 | this.before(function (beforeNode) { 15 | this.keys = Object.keys(beforeNode); 16 | this.keys.sort(function (a, b) { 17 | const aA = [a === 'id' ? 0 : 1, a]; 18 | const bA = [b === 'id' ? 0 : 1, b]; 19 | return aA < bA ? -1 : aA > bA ? 1 : 0; 20 | }); 21 | }); 22 | } 23 | if (this.isLeaf) { 24 | acc.push(node); 25 | } 26 | }); 27 | 28 | expect(acc.join(' ')).toBe('9 30 22'); 29 | }); 30 | 31 | test('sort test_modern', () => { 32 | const acc: any[] = []; 33 | 34 | new Traverse({ 35 | a: 30, 36 | b: 22, 37 | id: 9, 38 | }).forEach((ctx, node) => { 39 | if (!Array.isArray(node) && typeof node === 'object') { 40 | ctx.before((ctx_before, beforeNode) => { 41 | ctx_before.keys = Object.keys(beforeNode); 42 | ctx_before.keys.sort((a, b) => { 43 | const a_A = [a === 'id' ? 0 : 1, a]; 44 | const b_A = [b === 'id' ? 0 : 1, b]; 45 | return a_A < b_A ? -1 : a_A > b_A ? 1 : 0; 46 | }); 47 | }); 48 | } 49 | if (ctx.isLeaf) { 50 | acc.push(node); 51 | } 52 | }); 53 | 54 | expect(acc.join(' ')).toBe('9 30 22'); 55 | }); 56 | -------------------------------------------------------------------------------- /tsup.config.ts: -------------------------------------------------------------------------------- 1 | import { readFile, writeFile } from 'fs/promises'; 2 | import { defineConfig } from 'tsup'; 3 | 4 | export default defineConfig([ 5 | { 6 | entry: ['src/index.ts'], 7 | format: ['esm'], 8 | dts: true, 9 | sourcemap: false, 10 | clean: true, 11 | platform: 'browser', 12 | target: 'es2022', 13 | }, 14 | { 15 | entry: ['src/index.ts'], 16 | format: ['esm'], 17 | dts: false, 18 | sourcemap: false, 19 | clean: true, 20 | platform: 'browser', 21 | target: 'es2022', 22 | minify: 'terser', 23 | outDir: 'dist/min', 24 | }, 25 | { 26 | entry: ['src/modern.ts'], 27 | format: ['esm'], 28 | dts: true, 29 | sourcemap: false, 30 | clean: true, 31 | platform: 'browser', 32 | target: 'es2022', 33 | outDir: 'dist/modern', 34 | }, 35 | { 36 | entry: ['src/modern.ts'], 37 | format: ['esm'], 38 | dts: false, 39 | sourcemap: false, 40 | clean: false, 41 | platform: 'browser', 42 | target: 'es2022', 43 | minify: 'terser', 44 | outDir: 'dist/modern/min', 45 | }, 46 | { 47 | entry: ['src/legacy.cts'], 48 | format: ['cjs', 'esm'], 49 | outExtension(ctx) { 50 | return { js: ctx.format === 'cjs' ? '.cjs' : '.mjs' }; 51 | }, 52 | dts: true, 53 | sourcemap: false, 54 | clean: true, 55 | platform: 'neutral', 56 | target: 'es5', 57 | minify: false, 58 | outDir: 'dist/legacy', 59 | onSuccess: async () => { 60 | const file = await readFile('dist/legacy/legacy.mjs', 'utf-8'); 61 | await writeFile('dist/legacy/legacy.mjs', file.replace(/module\.exports = (.+);/, '')); 62 | }, 63 | }, 64 | ]); 65 | -------------------------------------------------------------------------------- /test/subexpr.test.ts: -------------------------------------------------------------------------------- 1 | import { expect, test } from 'vitest'; 2 | import traverse from '../src'; 3 | import { Traverse } from '../src/modern'; 4 | 5 | test('subexpr', () => { 6 | const obj = ['a', 4, 'b', 5, 'c', 6]; 7 | const r = traverse(obj).map(function (x) { 8 | if (typeof x === 'number') { 9 | this.update([x - 0.1, x, x + 0.1], true); 10 | } 11 | }); 12 | 13 | expect(obj).toEqual(['a', 4, 'b', 5, 'c', 6]); 14 | expect(r).toEqual(['a', [3.9, 4, 4.1], 'b', [4.9, 5, 5.1], 'c', [5.9, 6, 6.1]]); 15 | }); 16 | 17 | test('block', { skip: true }, () => { 18 | const obj = [[1], [2], [3]]; 19 | const r = traverse(obj).map(function (x) { 20 | if (Array.isArray(x) && !this.isRoot) { 21 | if (x[0] === 5) { 22 | this.block(); 23 | } else { 24 | this.update([[x[0] + 1]]); 25 | } 26 | } 27 | }); 28 | 29 | expect(r).toEqual([[[[[5]]]], [[[[5]]]], [[[5]]]]); 30 | }); 31 | 32 | test('subexpr_modern', () => { 33 | const obj = ['a', 4, 'b', 5, 'c', 6]; 34 | const r = new Traverse(obj).map((ctx, x) => { 35 | if (typeof x === 'number') { 36 | ctx.update([x - 0.1, x, x + 0.1], true); 37 | } 38 | }); 39 | 40 | expect(obj).toEqual(['a', 4, 'b', 5, 'c', 6]); 41 | expect(r).toEqual(['a', [3.9, 4, 4.1], 'b', [4.9, 5, 5.1], 'c', [5.9, 6, 6.1]]); 42 | }); 43 | 44 | test('block_modern', { skip: true }, () => { 45 | const obj = [[1], [2], [3]]; 46 | const r = new Traverse(obj).map((ctx, x) => { 47 | if (Array.isArray(x) && !ctx.isRoot) { 48 | if (x[0] === 5) { 49 | ctx.block(); 50 | } else { 51 | ctx.update([[x[0] + 1]]); 52 | } 53 | } 54 | }); 55 | 56 | expect(r).toEqual([[[[[5]]]], [[[[5]]]], [[[5]]]]); 57 | }); 58 | -------------------------------------------------------------------------------- /test/date.test.ts: -------------------------------------------------------------------------------- 1 | import { expect, test } from 'vitest'; 2 | import traverse from '../src'; 3 | import { Traverse } from '../src/modern'; 4 | 5 | test('dateEach', () => { 6 | const obj = { x: new Date(), y: 10, z: 5 }; 7 | 8 | const counts: Record = {}; 9 | 10 | traverse(obj).forEach(function (node) { 11 | const type = (node instanceof Date && 'Date') || typeof node; 12 | counts[type] = (counts[type] || 0) + 1; 13 | }); 14 | 15 | expect(counts).toEqual({ 16 | object: 1, 17 | Date: 1, 18 | number: 2, 19 | }); 20 | }); 21 | 22 | test('dateEach_modern', () => { 23 | const obj = { x: new Date(), y: 10, z: 5 }; 24 | 25 | const counts: Record = {}; 26 | 27 | new Traverse(obj).forEach((_, node) => { 28 | const type = (node instanceof Date && 'Date') || typeof node; 29 | counts[type] = (counts[type] || 0) + 1; 30 | }); 31 | 32 | expect(counts).toEqual({ 33 | object: 1, 34 | Date: 1, 35 | number: 2, 36 | }); 37 | }); 38 | 39 | test('dateMap', () => { 40 | const obj = { x: new Date(), y: 10, z: 5 }; 41 | 42 | const res = traverse(obj).map(function (node) { 43 | if (typeof node === 'number') { 44 | this.update(node + 100); 45 | } 46 | }); 47 | 48 | expect(obj.x).not.toBe(res.x); 49 | expect(res).toEqual({ 50 | x: obj.x, 51 | y: 110, 52 | z: 105, 53 | }); 54 | }); 55 | 56 | test('dateMap_modern', () => { 57 | const obj = { x: new Date(), y: 10, z: 5 }; 58 | 59 | const res = new Traverse(obj).map((ctx, node) => { 60 | if (typeof node === 'number') { 61 | ctx.update(node + 100); 62 | } 63 | }); 64 | 65 | expect(obj.x).not.toBe(res.x); 66 | expect(res).toEqual({ 67 | x: obj.x, 68 | y: 110, 69 | z: 105, 70 | }); 71 | }); 72 | -------------------------------------------------------------------------------- /CHANGELOG.md: -------------------------------------------------------------------------------- 1 | # Changelog 2 | 3 | ## 0.6.18 4 | 5 | ### Patch Changes 6 | 7 | - 07e5f02: fix: CI build 8 | 9 | ## 0.6.17 10 | 11 | ### Patch Changes 12 | 13 | - c73840d: fix: Actually add provenance 14 | 15 | ## 0.6.16 16 | 17 | ### Patch Changes 18 | 19 | - af2405a: patch: Add changesets, provenance 20 | 21 | ## 0.6.15 22 | 23 | PINNED: traverse@0.6.9 24 | 25 | ### Patch Changes 26 | 27 | Pin `engines` field to `>= 10` 28 | 29 | ## 0.6.14 30 | 31 | PINNED: traverse@0.6.9 32 | 33 | ### Patch Changes 34 | 35 | Fix regression in legacy.mjs introduced in 0.6.13. 36 | 37 | ## 0.6.13 38 | 39 | PINNED: traverse@0.6.9 40 | 41 | ### Patch Changes 42 | 43 | Fix types for neotraverse/legacy for pre-TypeScript 4.5(when export maps were not supported). 44 | 45 | ## 0.6.12 46 | 47 | PINNED: traverse@0.6.9 48 | 49 | ### Patch Changes 50 | 51 | Earlier, neotraverse/legacy did not work with WebPack 4, as it does not support export maps. Now this package provides direct fallback for CJS. 52 | 53 | ## 0.6.11 54 | 55 | PINNED: traverse@0.6.9 56 | 57 | ### Patch Changes 58 | 59 | Fix types for neotraverse/legacy. I am sacrificing types for CJS in favor of ESM. 60 | 61 | Use the following to get type-safety 62 | 63 | ```ts 64 | const traverse = require('neotraverse/legacy'); 65 | // ^ It isn't typed 66 | 67 | const neoTraverse = traverse as traverse['default']; 68 | // ^ It is typed 69 | ``` 70 | 71 | ## 0.6.10 72 | 73 | PINNED: traverse@0.6.9 74 | 75 | ### Patch Changes 76 | 77 | Fix types for neotraverse/legacy. Now both CJS and ESM are properly typed. CAVEAT: ESM import in typescript doesn't provide `TraverseContext` and `TraverseOptions` types. Import that from `neotraverse` instead. 78 | 79 | Fresh start. Check out the [CHANGELOG](https://github.com/ljharb/js-traverse/blob/main/CHANGELOG.md#v069---2024-04-08) 0.6.9 for a list of changes prior to this release. 80 | -------------------------------------------------------------------------------- /test/interface.test.ts: -------------------------------------------------------------------------------- 1 | import { expect, test } from 'vitest'; 2 | import traverse from '../src'; 3 | import { Traverse } from '../src/modern'; 4 | 5 | test('interface map', () => { 6 | const obj = { a: [5, 6, 7], b: { c: [8] } }; 7 | 8 | expect( 9 | traverse(obj) 10 | .paths() 11 | .sort() 12 | .map((path) => path.join('/')) 13 | .slice(1) 14 | .join(' '), 15 | ).toBe('a a/0 a/1 a/2 b b/c b/c/0'); 16 | 17 | expect(traverse(obj).nodes()).toEqual([ 18 | { a: [5, 6, 7], b: { c: [8] } }, 19 | [5, 6, 7], 20 | 5, 21 | 6, 22 | 7, 23 | { c: [8] }, 24 | [8], 25 | 8, 26 | ]); 27 | 28 | expect( 29 | traverse(obj).map((node) => { 30 | if (typeof node === 'number') { 31 | return node + 1000; 32 | } 33 | if (Array.isArray(node)) { 34 | return node.join(' '); 35 | } 36 | return void undefined; 37 | }), 38 | ).toEqual({ a: '5 6 7', b: { c: '8' } }); 39 | 40 | let nodes = 0; 41 | traverse(obj).forEach(function () { 42 | nodes += 1; 43 | }); 44 | 45 | expect(nodes).toBe(8); 46 | }); 47 | 48 | test('interface map_modern', () => { 49 | const obj = { a: [5, 6, 7], b: { c: [8] } }; 50 | 51 | expect( 52 | new Traverse(obj) 53 | .paths() 54 | .sort() 55 | .map((path) => path.join('/')) 56 | .slice(1) 57 | .join(' '), 58 | ).toBe('a a/0 a/1 a/2 b b/c b/c/0'); 59 | 60 | expect(new Traverse(obj).nodes()).toEqual([ 61 | { a: [5, 6, 7], b: { c: [8] } }, 62 | [5, 6, 7], 63 | 5, 64 | 6, 65 | 7, 66 | { c: [8] }, 67 | [8], 68 | 8, 69 | ]); 70 | 71 | expect( 72 | new Traverse(obj).map((_, node) => { 73 | if (typeof node === 'number') { 74 | return node + 1000; 75 | } 76 | if (Array.isArray(node)) { 77 | return node.join(' '); 78 | } 79 | return void undefined; 80 | }), 81 | ).toEqual({ a: '5 6 7', b: { c: '8' } }); 82 | 83 | let nodes = 0; 84 | new Traverse(obj).forEach(function () { 85 | nodes += 1; 86 | }); 87 | 88 | expect(nodes).toBe(8); 89 | }); 90 | -------------------------------------------------------------------------------- /test/json.test.ts: -------------------------------------------------------------------------------- 1 | import { expect, test } from 'vitest'; 2 | import traverse from '../src'; 3 | import { Traverse } from '../src/modern'; 4 | 5 | test('json test', () => { 6 | let id = 54; 7 | const callbacks: Record = {}; 8 | const obj = { moo: function () {}, foo: [2, 3, 4, function () {}] }; 9 | 10 | const scrubbed = traverse(obj).map(function (x) { 11 | if (typeof x === 'function') { 12 | callbacks[id] = { id: id, f: x, path: this.path }; 13 | this.update('[Function]'); 14 | id += 1; 15 | } 16 | }); 17 | 18 | expect(scrubbed.moo).toBe('[Function]'); 19 | expect(scrubbed.foo[3]).toBe('[Function]'); 20 | 21 | expect(scrubbed).toEqual({ 22 | moo: '[Function]', 23 | foo: [2, 3, 4, '[Function]'], 24 | }); 25 | 26 | expect(typeof obj.moo).toBe('function'); 27 | expect(typeof obj.foo[3]).toBe('function'); 28 | 29 | expect(callbacks).toEqual({ 30 | 54: { id: 54, f: obj.moo, path: ['moo'] }, 31 | 55: { id: 55, f: obj.foo[3], path: ['foo', '3'] }, 32 | }); 33 | }); 34 | 35 | test('json test_modern', () => { 36 | let id = 54; 37 | const callbacks: Record = {}; 38 | const obj = { moo: function () {}, foo: [2, 3, 4, function () {}] }; 39 | 40 | const scrubbed = new Traverse(obj).map((ctx, x) => { 41 | if (typeof x === 'function') { 42 | callbacks[id] = { id: id, f: x, path: ctx.path }; 43 | ctx.update('[Function]'); 44 | id += 1; 45 | } 46 | }); 47 | 48 | expect(scrubbed.moo).toBe('[Function]'); 49 | expect(scrubbed.foo[3]).toBe('[Function]'); 50 | 51 | expect(scrubbed).toEqual({ 52 | moo: '[Function]', 53 | foo: [2, 3, 4, '[Function]'], 54 | }); 55 | 56 | expect(typeof obj.moo).toBe('function'); 57 | expect(typeof obj.foo[3]).toBe('function'); 58 | 59 | expect(callbacks).toEqual({ 60 | 54: { id: 54, f: obj.moo, path: ['moo'] }, 61 | 55: { id: 55, f: obj.foo[3], path: ['foo', '3'] }, 62 | }); 63 | }); 64 | -------------------------------------------------------------------------------- /test/stringify.test.ts: -------------------------------------------------------------------------------- 1 | import { expect, test } from 'vitest'; 2 | import traverse from '../src'; 3 | import { Traverse } from '../src/modern'; 4 | 5 | test('stringify', () => { 6 | const obj = [5, 6, -3, [7, 8, -2, 1], { f: 10, g: -13 }]; 7 | 8 | let s = ''; 9 | traverse(obj).forEach(function (node) { 10 | if (Array.isArray(node)) { 11 | this.before(function () { 12 | s += '['; 13 | }); 14 | this.post(function (child) { 15 | if (!child.isLast) { 16 | s += ','; 17 | } 18 | }); 19 | this.after(function () { 20 | s += ']'; 21 | }); 22 | } else if (typeof node === 'object') { 23 | this.before(function () { 24 | s += '{'; 25 | }); 26 | this.pre(function (x, key) { 27 | s += '"' + key + '":'; 28 | }); 29 | this.post(function (child) { 30 | if (!child.isLast) { 31 | s += ','; 32 | } 33 | }); 34 | this.after(function () { 35 | s += '}'; 36 | }); 37 | } else if (typeof node === 'function') { 38 | s += 'null'; 39 | } else { 40 | s += node.toString(); 41 | } 42 | }); 43 | 44 | expect(s).toBe('[5,6,-3,[7,8,-2,1],{"f":10,"g":-13}]'); 45 | }); 46 | 47 | test('stringify_modern', () => { 48 | const obj = [5, 6, -3, [7, 8, -2, 1], { f: 10, g: -13 }]; 49 | 50 | let s = ''; 51 | new Traverse(obj).forEach((ctx, node) => { 52 | if (Array.isArray(node)) { 53 | ctx.before(() => { 54 | s += '['; 55 | }); 56 | ctx.post((_, child) => { 57 | if (!child.isLast) { 58 | s += ','; 59 | } 60 | }); 61 | ctx.after(() => { 62 | s += ']'; 63 | }); 64 | } else if (typeof node === 'object') { 65 | ctx.before(() => { 66 | s += '{'; 67 | }); 68 | ctx.pre((_, _x, key) => { 69 | s += '"' + key + '":'; 70 | }); 71 | ctx.post((_ctx, child) => { 72 | if (!child.isLast) { 73 | s += ','; 74 | } 75 | }); 76 | ctx.after(() => { 77 | s += '}'; 78 | }); 79 | } else if (typeof node === 'function') { 80 | s += 'null'; 81 | } else { 82 | s += node.toString(); 83 | } 84 | }); 85 | 86 | expect(s).toBe('[5,6,-3,[7,8,-2,1],{"f":10,"g":-13}]'); 87 | }); 88 | -------------------------------------------------------------------------------- /test/siblings.test.ts: -------------------------------------------------------------------------------- 1 | import { expect, test } from 'vitest'; 2 | import traverse from '../src'; 3 | import { Traverse } from '../src/modern'; 4 | 5 | test('siblings', () => { 6 | const obj = { a: 1, b: 2, c: [4, 5, 6] }; 7 | 8 | const res = traverse(obj).reduce(function (acc) { 9 | /* eslint no-param-reassign: 0 */ 10 | const p = '/' + this.path.join('/'); 11 | if (this.parent) { 12 | acc[p] = { 13 | siblings: this.parent.keys, 14 | key: this.key, 15 | index: this.key ? this.parent.keys?.indexOf(this.key) : -1, 16 | }; 17 | } else { 18 | acc[p] = { 19 | siblings: [], 20 | key: this.key, 21 | index: -1, 22 | }; 23 | } 24 | return acc; 25 | }, {}); 26 | 27 | expect(res).toEqual({ 28 | '/': { siblings: [], key: undefined, index: -1 }, 29 | '/a': { siblings: ['a', 'b', 'c'], key: 'a', index: 0 }, 30 | '/b': { siblings: ['a', 'b', 'c'], key: 'b', index: 1 }, 31 | '/c': { siblings: ['a', 'b', 'c'], key: 'c', index: 2 }, 32 | '/c/0': { siblings: ['0', '1', '2'], key: '0', index: 0 }, 33 | '/c/1': { siblings: ['0', '1', '2'], key: '1', index: 1 }, 34 | '/c/2': { siblings: ['0', '1', '2'], key: '2', index: 2 }, 35 | }); 36 | }); 37 | 38 | test('siblings_modern', () => { 39 | const obj = { a: 1, b: 2, c: [4, 5, 6] }; 40 | 41 | const res = new Traverse(obj).reduce((ctx, acc) => { 42 | /* eslint no-param-reassign: 0 */ 43 | const p = '/' + ctx.path.join('/'); 44 | if (ctx.parent) { 45 | acc[p] = { 46 | siblings: ctx.parent.keys, 47 | key: ctx.key, 48 | index: ctx.key ? ctx.parent.keys?.indexOf(ctx.key) : -1, 49 | }; 50 | } else { 51 | acc[p] = { 52 | siblings: [], 53 | key: ctx.key, 54 | index: -1, 55 | }; 56 | } 57 | return acc; 58 | }, {}); 59 | 60 | expect(res).toEqual({ 61 | '/': { siblings: [], key: undefined, index: -1 }, 62 | '/a': { siblings: ['a', 'b', 'c'], key: 'a', index: 0 }, 63 | '/b': { siblings: ['a', 'b', 'c'], key: 'b', index: 1 }, 64 | '/c': { siblings: ['a', 'b', 'c'], key: 'c', index: 2 }, 65 | '/c/0': { siblings: ['0', '1', '2'], key: '0', index: 0 }, 66 | '/c/1': { siblings: ['0', '1', '2'], key: '1', index: 1 }, 67 | '/c/2': { siblings: ['0', '1', '2'], key: '2', index: 2 }, 68 | }); 69 | }); 70 | -------------------------------------------------------------------------------- /test/stop.test.ts: -------------------------------------------------------------------------------- 1 | import { expect, test } from 'vitest'; 2 | import traverse from '../src'; 3 | import { Traverse } from '../src/modern'; 4 | 5 | test('stop', () => { 6 | let visits = 0; 7 | traverse('abcdefghij'.split('')).forEach(function (node) { 8 | if (typeof node === 'string') { 9 | visits += 1; 10 | if (node === 'e') { 11 | this.stop(); 12 | } 13 | } 14 | }); 15 | 16 | expect(visits).toBe(5); 17 | }); 18 | 19 | test('stop_modern', () => { 20 | let visits = 0; 21 | new Traverse('abcdefghij'.split('')).forEach((ctx, node) => { 22 | if (typeof node === 'string') { 23 | visits += 1; 24 | if (node === 'e') { 25 | ctx.stop(); 26 | } 27 | } 28 | }); 29 | 30 | expect(visits).toBe(5); 31 | }); 32 | 33 | test('stopMap', () => { 34 | const s = traverse('abcdefghij'.split('')) 35 | .map(function (node) { 36 | if (typeof node === 'string') { 37 | if (node === 'e') { 38 | this.stop(); 39 | } 40 | return node.toUpperCase(); 41 | } 42 | return void undefined; 43 | }) 44 | .join(''); 45 | 46 | expect(s).toBe('ABCDEfghij'); 47 | }); 48 | 49 | test('stopMap_modern', () => { 50 | const s = new Traverse('abcdefghij'.split('')) 51 | .map((ctx, node) => { 52 | if (typeof node === 'string') { 53 | if (node === 'e') { 54 | ctx.stop(); 55 | } 56 | return node.toUpperCase(); 57 | } 58 | return void undefined; 59 | }) 60 | .join(''); 61 | 62 | expect(s).toBe('ABCDEfghij'); 63 | }); 64 | 65 | test('stopReduce', () => { 66 | const obj = { 67 | a: [4, 5], 68 | b: [6, [7, 8, 9]], 69 | }; 70 | const xs = traverse(obj).reduce(function (acc, node) { 71 | if (this.isLeaf) { 72 | if (node === 7) { 73 | this.stop(); 74 | } else { 75 | acc.push(node); 76 | } 77 | } 78 | return acc; 79 | }, []); 80 | 81 | expect(xs).toEqual([4, 5, 6]); 82 | }); 83 | 84 | test('stopReduce_modern', () => { 85 | const obj = { 86 | a: [4, 5], 87 | b: [6, [7, 8, 9]], 88 | }; 89 | const xs = new Traverse(obj).reduce((ctx, acc, node) => { 90 | if (ctx.isLeaf) { 91 | if (node === 7) { 92 | ctx.stop(); 93 | } else { 94 | acc.push(node); 95 | } 96 | } 97 | return acc; 98 | }, []); 99 | 100 | expect(xs).toEqual([4, 5, 6]); 101 | }); 102 | -------------------------------------------------------------------------------- /package.json: -------------------------------------------------------------------------------- 1 | { 2 | "name": "neotraverse", 3 | "version": "0.6.18", 4 | "description": "traverse and transform objects by visiting every node on a recursive walk", 5 | "main": "dist/legacy/legacy.cjs", 6 | "type": "module", 7 | "types": "dist/index.d.ts", 8 | "files": [ 9 | "dist", 10 | "legacy.*" 11 | ], 12 | "exports": { 13 | ".": { 14 | "types": "./dist/index.d.ts", 15 | "import": { 16 | "production": "./dist/min/index.js", 17 | "development": "./dist/index.js", 18 | "default": "./dist/index.js" 19 | }, 20 | "default": "./dist/min/index.js" 21 | }, 22 | "./modern": { 23 | "types": "./dist/modern/modern.d.ts", 24 | "import": { 25 | "production": "./dist/modern/min/modern.js", 26 | "development": "./dist/modern/modern.js", 27 | "default": "./dist/modern/modern.js" 28 | }, 29 | "default": "./dist/modern/modern.js" 30 | }, 31 | "./legacy": { 32 | "require": { 33 | "types": "./dist/legacy/legacy.d.cts", 34 | "default": "./dist/legacy/legacy.cjs" 35 | }, 36 | "import": { 37 | "types": "./dist/legacy/legacy.d.ts", 38 | "default": "./dist/legacy/legacy.mjs" 39 | }, 40 | "default": "./dist/legacy/legacy.cjs" 41 | }, 42 | "./package.json": "./package.json" 43 | }, 44 | "scripts": { 45 | "compile": "tsup && cp dist/legacy/legacy.cjs legacy.js && cp dist/legacy/legacy.d.cts legacy.d.ts", 46 | "test": "vitest run", 47 | "test:cov": "vitest run --coverage", 48 | "pub": "pnpm run compile && npm publish --access public --no-git-checks", 49 | "changeset": "changeset", 50 | "ci:version": "changeset version", 51 | "ci:release": "changeset publish" 52 | }, 53 | "repository": { 54 | "type": "git", 55 | "url": "https://github.com/PuruVJ/neotraverse.git" 56 | }, 57 | "homepage": "https://github.com/PuruVJ/neotraverse", 58 | "keywords": [ 59 | "traverse", 60 | "walk", 61 | "recursive", 62 | "map", 63 | "forEach", 64 | "deep", 65 | "clone" 66 | ], 67 | "author": { 68 | "name": "Puru Vijay, James Halliday" 69 | }, 70 | "publishConfig": { 71 | "provenance": true 72 | }, 73 | "license": "MIT", 74 | "engines": { 75 | "node": ">= 10" 76 | }, 77 | "devDependencies": { 78 | "@changesets/cli": "^2.27.7", 79 | "@swc/core": "^1.6.13", 80 | "@types/node": "^20.14.10", 81 | "@vitest/coverage-v8": "^2.0.5", 82 | "terser": "^5.31.2", 83 | "tsup": "^8.1.0", 84 | "typescript": "^5.5.3", 85 | "vitest": "^2.0.5" 86 | } 87 | } 88 | -------------------------------------------------------------------------------- /test/has.test.ts: -------------------------------------------------------------------------------- 1 | import { describe, expect, test } from 'vitest'; 2 | import traverse from '../src'; 3 | import { Traverse } from '../src/modern'; 4 | 5 | describe('has', () => { 6 | const obj: any = { a: 2, b: [4, 5, { c: 6 }] }; 7 | 8 | expect(traverse(obj).has(['b', 2, 'c'])).toBe(true); 9 | expect(traverse(obj).has(['b', 2, 'c', 0])).toBe(false); 10 | expect(traverse(obj).has(['b', 2, 'd'])).toBe(false); 11 | expect(traverse(obj).has([])).toBe(true); 12 | expect(traverse(obj).has(['a'])).toBe(true); 13 | expect(traverse(obj).has(['a', 2])).toBe(false); 14 | 15 | test('symbols', () => { 16 | /* eslint no-restricted-properties: 1 */ 17 | const globalSymbol = Symbol.for('d'); 18 | const localSymbol = Symbol('e'); 19 | 20 | obj[globalSymbol] = {}; 21 | obj[globalSymbol][localSymbol] = 7; 22 | obj[localSymbol] = 8; 23 | 24 | expect(traverse(obj).has([globalSymbol])).toBe(false); 25 | expect(traverse(obj, { includeSymbols: true }).has([globalSymbol])).toBe(true); 26 | 27 | expect(traverse(obj).has([globalSymbol, globalSymbol])).toBe(false); 28 | expect(traverse(obj, { includeSymbols: true }).has([globalSymbol, globalSymbol])).toBe(false); 29 | 30 | expect(traverse(obj).has([globalSymbol, localSymbol])).toBe(false); 31 | expect(traverse(obj, { includeSymbols: true }).has([globalSymbol, localSymbol])).toBe(true); 32 | 33 | expect(traverse(obj).has([localSymbol])).toBe(false); 34 | expect(traverse(obj, { includeSymbols: true }).has([localSymbol])).toBe(true); 35 | 36 | expect(traverse(obj).has([Symbol('d')])).toBe(false); 37 | expect(traverse(obj, { includeSymbols: true }).has([Symbol('d')])).toBe(false); 38 | 39 | expect(traverse(obj).has([Symbol('e')])).toBe(false); 40 | }); 41 | }); 42 | 43 | describe('has_modern', () => { 44 | const obj: any = { a: 2, b: [4, 5, { c: 6 }] }; 45 | 46 | expect(new Traverse(obj).has(['b', 2, 'c'])).toBe(true); 47 | expect(new Traverse(obj).has(['b', 2, 'c', 0])).toBe(false); 48 | expect(new Traverse(obj).has(['b', 2, 'd'])).toBe(false); 49 | expect(new Traverse(obj).has([])).toBe(true); 50 | expect(new Traverse(obj).has(['a'])).toBe(true); 51 | expect(new Traverse(obj).has(['a', 2])).toBe(false); 52 | 53 | test('symbols', () => { 54 | /* eslint no-restricted-properties: 1 */ 55 | const globalSymbol = Symbol.for('d'); 56 | const localSymbol = Symbol('e'); 57 | 58 | obj[globalSymbol] = {}; 59 | obj[globalSymbol][localSymbol] = 7; 60 | obj[localSymbol] = 8; 61 | 62 | expect(new Traverse(obj).has([globalSymbol])).toBe(false); 63 | expect(new Traverse(obj, { includeSymbols: true }).has([globalSymbol])).toBe(true); 64 | 65 | expect(new Traverse(obj).has([globalSymbol, globalSymbol])).toBe(false); 66 | expect(new Traverse(obj, { includeSymbols: true }).has([globalSymbol, globalSymbol])).toBe( 67 | false, 68 | ); 69 | 70 | expect(new Traverse(obj).has([globalSymbol, localSymbol])).toBe(false); 71 | expect(new Traverse(obj, { includeSymbols: true }).has([globalSymbol, localSymbol])).toBe(true); 72 | 73 | expect(new Traverse(obj).has([localSymbol])).toBe(false); 74 | expect(new Traverse(obj, { includeSymbols: true }).has([localSymbol])).toBe(true); 75 | 76 | expect(new Traverse(obj).has([Symbol('d')])).toBe(false); 77 | expect(new Traverse(obj, { includeSymbols: true }).has([Symbol('d')])).toBe(false); 78 | 79 | expect(new Traverse(obj).has([Symbol('e')])).toBe(false); 80 | }); 81 | }); 82 | -------------------------------------------------------------------------------- /test/circular.test.ts: -------------------------------------------------------------------------------- 1 | import { expect, test } from 'vitest'; 2 | import traverse from '../src'; 3 | import { Traverse } from '../src/modern'; 4 | 5 | test('circular', () => { 6 | const obj = { x: 3 }; 7 | // @ts-expect-error 8 | obj.y = obj; 9 | traverse(obj).forEach(function () { 10 | if (this.path.join('') === 'y') { 11 | // t.equal(util.inspect(this.circular.node), util.inspect(obj)); 12 | expect(this.circular?.node).toEqual(obj); 13 | } 14 | }); 15 | }); 16 | 17 | test('circular_modern', () => { 18 | const obj = { x: 3 }; 19 | // @ts-expect-error 20 | obj.y = obj; 21 | 22 | new Traverse(obj).forEach((ctx) => { 23 | if (ctx.path.join('') === 'y') { 24 | // t.equal(util.inspect(this.circular.node), util.inspect(obj)); 25 | expect(ctx.circular?.node).toEqual(obj); 26 | } 27 | }); 28 | }); 29 | 30 | test('deepCirc', () => { 31 | const obj = { x: [1, 2, 3], y: [4, 5] }; 32 | // @ts-expect-error 33 | obj.y[2] = obj; 34 | 35 | traverse(obj).forEach(function () { 36 | if (this.circular) { 37 | expect(this.circular?.path).toEqual([]); 38 | expect(this.path).toEqual(['y', '2']); 39 | } 40 | }); 41 | }); 42 | 43 | test('deepCirc_modern', () => { 44 | const obj = { x: [1, 2, 3], y: [4, 5] }; 45 | // @ts-expect-error 46 | obj.y[2] = obj; 47 | 48 | new Traverse(obj).forEach((ctx) => { 49 | if (ctx.circular) { 50 | expect(ctx.circular?.path).toEqual([]); 51 | expect(ctx.path).toEqual(['y', '2']); 52 | } 53 | }); 54 | }); 55 | 56 | test('doubleCirc', () => { 57 | const obj = { x: [1, 2, 3], y: [4, 5] }; 58 | // @ts-expect-error 59 | obj.y[2] = obj; 60 | // @ts-expect-error 61 | obj.x.push(obj.y); 62 | 63 | const circs: any[] = []; 64 | traverse(obj).forEach(function (x) { 65 | if (this.circular) { 66 | circs.push({ circ: this.circular, self: this, node: x }); 67 | } 68 | }); 69 | 70 | expect(circs[0].self.path).toEqual(['x', '3', '2']); 71 | expect(circs[0].circ.path).toEqual([]); 72 | 73 | expect(circs[1].self.path).toEqual(['y', '2']); 74 | expect(circs[1].circ.path).toEqual([]); 75 | 76 | expect(circs.length).toEqual(2); 77 | }); 78 | 79 | test('doubleCirc_modern', () => { 80 | const obj = { x: [1, 2, 3], y: [4, 5] }; 81 | // @ts-expect-error 82 | obj.y[2] = obj; 83 | // @ts-expect-error 84 | obj.x.push(obj.y); 85 | 86 | const circs: any[] = []; 87 | new Traverse(obj).forEach((ctx, x) => { 88 | if (ctx.circular) { 89 | circs.push({ circ: ctx.circular, self: ctx, node: x }); 90 | } 91 | }); 92 | 93 | expect(circs[0].self.path).toEqual(['x', '3', '2']); 94 | expect(circs[0].circ.path).toEqual([]); 95 | 96 | expect(circs[1].self.path).toEqual(['y', '2']); 97 | expect(circs[1].circ.path).toEqual([]); 98 | 99 | expect(circs.length).toEqual(2); 100 | }); 101 | 102 | test('circDubForEach', () => { 103 | const obj = { x: [1, 2, 3], y: [4, 5] }; 104 | // @ts-expect-error 105 | obj.y[2] = obj; 106 | // @ts-expect-error 107 | obj.x.push(obj.y); 108 | 109 | traverse(obj).forEach(function () { 110 | if (this.circular) { 111 | this.update('...'); 112 | } 113 | }); 114 | 115 | expect(obj).toEqual({ x: [1, 2, 3, [4, 5, '...']], y: [4, 5, '...'] }); 116 | }); 117 | 118 | test('circDubForEach_modern', () => { 119 | const obj = { x: [1, 2, 3], y: [4, 5] }; 120 | // @ts-expect-error 121 | obj.y[2] = obj; 122 | // @ts-expect-error 123 | obj.x.push(obj.y); 124 | 125 | new Traverse(obj).forEach((ctx) => { 126 | if (ctx.circular) { 127 | ctx.update('...'); 128 | } 129 | }); 130 | 131 | expect(obj).toEqual({ x: [1, 2, 3, [4, 5, '...']], y: [4, 5, '...'] }); 132 | }); 133 | 134 | test('circDubMap', () => { 135 | const obj = { x: [1, 2, 3], y: [4, 5] }; 136 | // @ts-expect-error 137 | obj.y[2] = obj; 138 | // @ts-expect-error 139 | obj.x.push(obj.y); 140 | 141 | const c = traverse(obj).map(function () { 142 | if (this.circular) { 143 | this.update('...'); 144 | } 145 | }); 146 | 147 | expect(c).toEqual({ x: [1, 2, 3, [4, 5, '...']], y: [4, 5, '...'] }); 148 | }); 149 | 150 | test('circMapScrub_modern', () => { 151 | const obj = { a: 1, b: 2 }; 152 | // @ts-expect-error 153 | obj.c = obj; 154 | 155 | const scrubbed = new Traverse(obj).map((ctx) => { 156 | if (ctx.circular) { 157 | ctx.remove(); 158 | } 159 | }); 160 | expect(Object.keys(scrubbed).sort()).toEqual(['a', 'b']); 161 | expect(scrubbed).toEqual({ a: 1, b: 2 }); 162 | 163 | // @ts-expect-error 164 | expect(obj.c).toBe(obj); 165 | }); 166 | 167 | test('circClone', () => { 168 | const obj = { x: [1, 2, 3], y: [4, 5] }; 169 | // @ts-expect-error 170 | obj.y[2] = obj; 171 | // @ts-expect-error 172 | obj.x.push(obj.y); 173 | 174 | const clone = traverse(obj).clone(); 175 | expect(obj).not.toBe(clone); 176 | 177 | expect(clone.y[2]).toBe(clone); 178 | expect(clone.y[2]).not.toBe(obj); 179 | expect(clone.x[3][2]).toBe(clone); 180 | expect(clone.x[3][2]).not.toBe(obj); 181 | expect(clone.x.slice(0, 3)).toEqual([1, 2, 3]); 182 | expect(clone.y.slice(0, 2)).toEqual([4, 5]); 183 | }); 184 | 185 | test('clone_modern', () => { 186 | const obj = { x: [1, 2, 3], y: [4, 5] }; 187 | // @ts-expect-error 188 | obj.y[2] = obj; 189 | // @ts-expect-error 190 | obj.x.push(obj.y); 191 | 192 | const clone = new Traverse(obj).clone(); 193 | expect(obj).not.toBe(clone); 194 | 195 | expect(clone.y[2]).toBe(clone); 196 | expect(clone.y[2]).not.toBe(obj); 197 | expect(clone.x[3][2]).toBe(clone); 198 | expect(clone.x[3][2]).not.toBe(obj); 199 | expect(clone.x.slice(0, 3)).toEqual([1, 2, 3]); 200 | expect(clone.y.slice(0, 2)).toEqual([4, 5]); 201 | }); 202 | 203 | test('circMapScrub', () => { 204 | const obj = { a: 1, b: 2 }; 205 | // @ts-expect-error 206 | obj.c = obj; 207 | 208 | const scrubbed = traverse(obj).map(function () { 209 | if (this.circular) { 210 | this.remove(); 211 | } 212 | }); 213 | expect(Object.keys(scrubbed).sort()).toEqual(['a', 'b']); 214 | expect(scrubbed).toEqual({ a: 1, b: 2 }); 215 | 216 | // @ts-expect-error 217 | expect(obj.c).toBe(obj); 218 | }); 219 | 220 | test('scrub_modern', () => { 221 | const obj = { a: 1, b: 2 }; 222 | // @ts-expect-error 223 | obj.c = obj; 224 | 225 | const scrubbed = new Traverse(obj).map((ctx) => { 226 | if (ctx.circular) { 227 | ctx.remove(); 228 | } 229 | }); 230 | expect(Object.keys(scrubbed).sort()).toEqual(['a', 'b']); 231 | expect(scrubbed).toEqual({ a: 1, b: 2 }); 232 | 233 | // @ts-expect-error 234 | expect(obj.c).toBe(obj); 235 | }); 236 | -------------------------------------------------------------------------------- /README.md: -------------------------------------------------------------------------------- 1 | # neotraverse 2 | 3 | Traverse and transform objects by visiting every node on a recursive walk. This is a fork and TypeScript rewrite of [traverse](https://github.com/ljharb/js-traverse) with 0 dependencies and major improvements: 4 | 5 | - 🤌 1.38KB min+brotli 6 | - 🚥 Zero dependencies 7 | - 🎹 TypeScript. Throw away the `@types/traverse` package 8 | - ❎ No polyfills 9 | - 🛸 ESM-first 10 | - 📜 Legacy mode supporting ES5 11 | 12 | # Principles 13 | 14 | Rules this package aims to follow for an indefinite period of time: 15 | 16 | - No dependencies. 17 | - No polyfills. 18 | - ESM-first. 19 | - Pushing to be modern 20 | - Always provide a legacy mode 21 | - Always follow `traverse` API. There already are many packages that do this. `neotraverse` intends to be a drop-in replacement for `traverse` and provide the same API with 0 dependencies and enhanced Developer Experience. 22 | - All deviating changes happen in `neotraverse/modern` build. 23 | 24 | # Modern build 25 | 26 | `neotraverse/modern` provides a new class `new Traverse()`, and all methods and state is provided as first argument `ctx` (`this.update -> ctx.update`, `this.isLeaf -> ctx.isLeaf`, etc.) 27 | 28 | Before: 29 | 30 | ```js 31 | import traverse from 'neotraverse'; 32 | 33 | const obj = { a: 1, b: 2, c: [3, 4] }; 34 | 35 | traverse(obj).forEach(function (x) { 36 | if (x < 0) this.update(x + 128); 37 | }); 38 | ``` 39 | 40 | After: 41 | 42 | ```js 43 | import { Traverse } from 'neotraverse/modern'; 44 | 45 | const obj = { a: 1, b: 2, c: [3, 4] }; 46 | 47 | new Traverse(obj).forEach((ctx, x) => { 48 | if (x < 0) ctx.update(x + 128); 49 | }); 50 | ``` 51 | 52 | # Which build to use? 53 | 54 | `neotraverse` provides 3 builds: 55 | 56 | - default: Backwards compatible with `traverse` and provides the same API, but ESM only and compiled to ES2022 with Node 18+ 57 | - modern: Modern build with ESM only and compiled to ES2022 with Node 18+. Provides a new class `new Traverse()`, and all methods and state is provided as first argument `ctx` (`this.update -> ctx.update`, `this.isLeaf -> ctx.isLeaf`, etc.) 58 | - legacy: Legacy build with ES5 and CJS, compatible with `traverse` and provides the same API. 59 | 60 | Here's a matrix of the different builds: 61 | 62 | | Build | ESM | CJS | Browser | Node | Polyfills | Size | 63 | | ------- | --------- | --- | ------- | ---- | --------- | ----------------- | 64 | | default | ✅ ES2022 | | ✅ | ✅ | ❌ | 1.54KB min+brotli | 65 | | modern | ✅ ES2022 | | ✅ | ✅ | ❌ | 1.38KB min+brotli | 66 | | legacy | ✅ ES5 | ✅ | ✅ | ✅ | ❌ | 2.73KB min+brotli | 67 | 68 | If you are: 69 | 70 | ## starting from scratch 71 | 72 | ```ts 73 | import { Traverse } from 'neotraverse/modern'; 74 | 75 | const obj = { a: 1, b: 2, c: [3, 4] }; 76 | 77 | new Traverse(obj).forEach((ctx, x) => { 78 | if (x < 0) ctx.update(x + 128); // `this` is same as `ctx` when using regular function 79 | }); 80 | ``` 81 | 82 | ## migrating from `traverse` 83 | 84 | ### and you don't care about old browsers or Node versions: 85 | 86 | Use default build for no breaking changes, and a modern build for better developer experience. 87 | 88 | ```ts 89 | import traverse from 'neotraverse'; 90 | 91 | const obj = { a: 1, b: 2, c: [3, 4] }; 92 | 93 | traverse(obj).forEach(function (x) { 94 | if (x < 0) this.update(x + 128); 95 | }); 96 | ``` 97 | 98 | ### and you care about old browsers or Node versions: 99 | 100 | Use legacy build for compatibility with old browsers and Node versions. 101 | 102 | ```js 103 | const traverse = require('neotraverse/legacy'); 104 | ``` 105 | 106 | ESM: 107 | 108 | ```js 109 | import traverse from 'neotraverse/legacy'; 110 | ``` 111 | 112 | # examples 113 | 114 | ## transform negative numbers in-place 115 | 116 | negative.js 117 | 118 | ```js 119 | import { Traverse } from 'neotraverse/modern'; 120 | const obj = [5, 6, -3, [7, 8, -2, 1], { f: 10, g: -13 }]; 121 | 122 | new Traverse(obj).forEach(function (ctx, x) { 123 | if (x < 0) ctx.update(x + 128); 124 | }); 125 | 126 | console.dir(obj); 127 | ``` 128 | 129 | or in legacy mode: 130 | 131 | ```js 132 | import traverse from 'neotraverse'; 133 | // OR import traverse from 'neotraverse/legacy'; 134 | 135 | const obj = [5, 6, -3, [7, 8, -2, 1], { f: 10, g: -13 }]; 136 | 137 | traverse(obj).forEach(function (x) { 138 | if (x < 0) this.update(x + 128); 139 | }); 140 | 141 | // This is identical to the above 142 | traverse.forEach(obj, function (x) { 143 | if (x < 0) this.update(x + 128); 144 | }); 145 | 146 | console.dir(obj); 147 | ``` 148 | 149 | Output: 150 | 151 | [ 5, 6, 125, [ 7, 8, 126, 1 ], { f: 10, g: 115 } ] 152 | 153 | ## collect leaf nodes 154 | 155 | leaves.js 156 | 157 | ```js 158 | import { Traverse } from 'neotraverse/modern'; 159 | 160 | const obj = { 161 | a: [1, 2, 3], 162 | b: 4, 163 | c: [5, 6], 164 | d: { e: [7, 8], f: 9 } 165 | }; 166 | 167 | const leaves = new Traverse(obj).reduce((ctx, acc, x) => { 168 | if (ctx.isLeaf) acc.push(x); 169 | return acc; 170 | }, []); 171 | 172 | console.dir(leaves); 173 | ``` 174 | 175 | or in legacy mode: 176 | 177 | ```js 178 | import traverse from 'neotraverse'; 179 | // OR import traverse from 'neotraverse/legacy'; 180 | 181 | const obj = { 182 | a: [1, 2, 3], 183 | b: 4, 184 | c: [5, 6], 185 | d: { e: [7, 8], f: 9 } 186 | }; 187 | 188 | const leaves = traverse(obj).reduce(function (acc, x) { 189 | if (this.isLeaf) acc.push(x); 190 | return acc; 191 | }, []); 192 | 193 | // Equivalent to the above 194 | const leavesLegacy = traverse.reduce( 195 | obj, 196 | function (acc, x) { 197 | if (this.isLeaf) acc.push(x); 198 | return acc; 199 | }, 200 | [] 201 | ); 202 | 203 | console.dir(leaves); 204 | console.dir(leavesLegacy); 205 | ``` 206 | 207 | Output: 208 | 209 | [ 1, 2, 3, 4, 5, 6, 7, 8, 9 ] 210 | 211 | ## scrub circular references 212 | 213 | scrub.js: 214 | 215 | ```js 216 | import { Traverse } from 'neotraverse/modern'; 217 | 218 | const obj = { a: 1, b: 2, c: [3, 4] }; 219 | obj.c.push(obj); 220 | 221 | const scrubbed = new Traverse(obj).map(function (ctx, x) { 222 | if (ctx.circular) ctx.remove(); 223 | }); 224 | 225 | console.dir(scrubbed); 226 | ``` 227 | 228 | or in legacy mode: 229 | 230 | ```js 231 | import traverse from 'neotraverse'; 232 | // OR import traverse from 'neotraverse/legacy'; 233 | 234 | const obj = { a: 1, b: 2, c: [3, 4] }; 235 | obj.c.push(obj); 236 | 237 | const scrubbed = traverse(obj).map(function (x) { 238 | if (this.circular) this.remove(); 239 | }); 240 | 241 | // Equivalent to the above 242 | const scrubbedLegacy = traverse.map(obj, function (x) { 243 | if (this.circular) this.remove(); 244 | }); 245 | 246 | console.dir(scrubbed); 247 | console.dir(scrubbedLegacy); 248 | ``` 249 | 250 | output: 251 | 252 | { a: 1, b: 2, c: [ 3, 4 ] } 253 | 254 | ## commonjs 255 | 256 | neotraverse/legacy is compatible with commonjs and provides the same API as `traverse`, acting as a drop-in replacement: 257 | 258 | ```js 259 | const traverse = require('neotraverse/legacy'); 260 | ``` 261 | 262 | ## esm 263 | 264 | ```js 265 | import { Traverse } from 'neotraverse/modern'; 266 | ``` 267 | 268 | ```js 269 | import traverse from 'neotraverse'; 270 | ``` 271 | 272 | # Differences from `traverse` 273 | 274 | - ESM-first 275 | - ES2022, Node 18+ 276 | - Types included by default. No need to install `@types/traverse` 277 | - Works as-is in all major browsers and Deno 278 | - No polyfills 279 | - `new Traverse()` class instead of regular old `traverse()` 280 | - Legacy mode supporting `ES5` and `CJS` 281 | 282 | There is a legacy mode that provides the same API as `traverse`, acting as a drop-in replacement: 283 | 284 | ```js 285 | import traverse from 'neotraverse'; 286 | 287 | const obj = { a: 1, b: 2, c: [3, 4] }; 288 | 289 | traverse(obj).forEach(function (x) { 290 | if (x < 0) this.update(x + 128); 291 | }); 292 | ``` 293 | 294 | If you want to support really old browsers or NodeJS, supporting ES5, there's `neotraverse/legacy` which is compatible with ES5 and provides the same API as `traverse`, acting as a drop-in replacement for older browsers: 295 | 296 | ```js 297 | import traverse from 'neotraverse/legacy'; 298 | 299 | const obj = { a: 1, b: 2, c: [3, 4] }; 300 | 301 | traverse(obj).forEach(function (x) { 302 | if (x < 0) this.update(x + 128); 303 | }); 304 | ``` 305 | 306 | # Migrating from `traverse` 307 | 308 | ### Step 1: Install `neotraverse` 309 | 310 | ```sh 311 | npm install neotraverse 312 | npm uninstall traverse @types/traverse # Remove the old dependencies 313 | ``` 314 | 315 | ### Step 2: Replace `traverse` with `neotraverse` 316 | 317 | ```diff 318 | -import traverse from 'traverse'; 319 | +import traverse from 'neotraverse'; 320 | 321 | const obj = { a: 1, b: 2, c: [3, 4] }; 322 | 323 | -traverse(obj).forEach(function (x) { 324 | +traverse(obj).forEach(function (x) { 325 | if (x < 0) this.update(x + 128); 326 | }); 327 | ``` 328 | 329 | Optionally, there's also a legacy mode that provides the same API as `traverse`, acting as a drop-in replacement: 330 | 331 | ```js 332 | import traverse from 'neotraverse/legacy'; 333 | 334 | const obj = { a: 1, b: 2, c: [3, 4] }; 335 | 336 | traverse(obj).forEach(function (x) { 337 | if (x < 0) this.update(x + 128); 338 | }); 339 | ``` 340 | 341 | ### Step 3(Optional): Bundle time aliasing 342 | 343 | If you use Vite, you can aliss `traverse` to `neotravers/legacy` in your `vite.config.js`: 344 | 345 | ```js 346 | import { defineConfig } from 'vite'; 347 | 348 | export default defineConfig({ 349 | resolve: { 350 | alias: { 351 | traverse: 'neotraverse' // or 'neotraverse/legacy' 352 | } 353 | } 354 | }); 355 | ``` 356 | 357 | # methods 358 | 359 | Each method that takes an `fn` uses the context documented below in the context section. 360 | 361 | ## .map(fn) 362 | 363 | Execute `fn` for each node in the object and return a new object with the results of the walk. To update nodes in the result use `ctx.update(value)`(modern) or `this.update(value)`(legacy). 364 | 365 | ## .forEach(fn) 366 | 367 | Execute `fn` for each node in the object but unlike `.map()`, when `ctx.update()`(modern) or `this.update()`(legacy) is called it updates the object in-place. 368 | 369 | ## .reduce(fn, acc) 370 | 371 | For each node in the object, perform a [left-fold]() with the return value of `fn(acc, node)`. 372 | 373 | If `acc` isn't specified, `acc` is set to the root object for the first step and the root element is skipped. 374 | 375 | ## .paths() 376 | 377 | Return an `Array` of every possible non-cyclic path in the object. Paths are `Array`s of string keys. 378 | 379 | ## .nodes() 380 | 381 | Return an `Array` of every node in the object. 382 | 383 | ## .clone() 384 | 385 | Create a deep clone of the object. 386 | 387 | ## .get(path) 388 | 389 | Get the element at the array `path`. 390 | 391 | ## .set(path, value) 392 | 393 | Set the element at the array `path` to `value`. 394 | 395 | ## .has(path) 396 | 397 | Return whether the element at the array `path` exists. 398 | 399 | # context 400 | 401 | Each method that takes a callback has a context (its `ctx` object, or `this` object in legacy mode) with these attributes: 402 | 403 | ## this.node 404 | 405 | The present node on the recursive walk 406 | 407 | ## this.path 408 | 409 | An array of string keys from the root to the present node 410 | 411 | ## this.parent 412 | 413 | The context of the node's parent. This is `undefined` for the root node. 414 | 415 | ## this.key 416 | 417 | The name of the key of the present node in its parent. This is `undefined` for the root node. 418 | 419 | ## this.isRoot, this.notRoot 420 | 421 | Whether the present node is the root node 422 | 423 | ## this.isLeaf, this.notLeaf 424 | 425 | Whether or not the present node is a leaf node (has no children) 426 | 427 | ## this.level 428 | 429 | Depth of the node within the traversal 430 | 431 | ## this.circular 432 | 433 | If the node equals one of its parents, the `circular` attribute is set to the context of that parent and the traversal progresses no deeper. 434 | 435 | ## this.update(value, stopHere=false) 436 | 437 | Set a new value for the present node. 438 | 439 | All the elements in `value` will be recursively traversed unless `stopHere` is true. 440 | 441 | ## this.remove(stopHere=false) 442 | 443 | Remove the current element from the output. If the node is in an Array it will be spliced off. Otherwise it will be deleted from its parent. 444 | 445 | ## this.delete(stopHere=false) 446 | 447 | Delete the current element from its parent in the output. Calls `delete` even on Arrays. 448 | 449 | ## this.before(fn) 450 | 451 | Call this function before any of the children are traversed. 452 | 453 | You can assign into `ctx.keys`(modern) or `this.keys`(legacy) here to traverse in a custom order. 454 | 455 | ## this.after(fn) 456 | 457 | Call this function after any of the children are traversed. 458 | 459 | ## this.pre(fn) 460 | 461 | Call this function before each of the children are traversed. 462 | 463 | ## this.post(fn) 464 | 465 | Call this function after each of the children are traversed. 466 | 467 | # license 468 | 469 | MIT 470 | -------------------------------------------------------------------------------- /test/mutability.test.ts: -------------------------------------------------------------------------------- 1 | import assert from 'node:assert'; 2 | import { expect, test } from 'vitest'; 3 | import traverse from '../src'; 4 | import { Traverse } from '../src/modern'; 5 | 6 | test('mutate', () => { 7 | const obj = { a: 1, b: 2, c: [3, 4] }; 8 | const res = traverse(obj).forEach(function (x) { 9 | if (typeof x === 'number' && x % 2 === 0) { 10 | this.update(x * 10); 11 | } 12 | }); 13 | 14 | expect(obj).toEqual(res); 15 | expect(obj).toEqual({ a: 1, b: 20, c: [3, 40] }); 16 | }); 17 | 18 | test('mutate_modern', () => { 19 | const obj = { a: 1, b: 2, c: [3, 4] }; 20 | const res = new Traverse(obj).forEach((ctx, x) => { 21 | if (typeof x === 'number' && x % 2 === 0) { 22 | ctx.update(x * 10); 23 | } 24 | }); 25 | 26 | expect(obj).toEqual(res); 27 | expect(obj).toEqual({ a: 1, b: 20, c: [3, 40] }); 28 | }); 29 | 30 | test('map', () => { 31 | const obj = { a: 1, b: 2, c: [3, 4] }; 32 | const res = traverse(obj).map(function (x) { 33 | if (typeof x === 'number' && x % 2 === 0) { 34 | this.update(x * 10); 35 | } 36 | }); 37 | 38 | expect(obj).toEqual({ a: 1, b: 2, c: [3, 4] }); 39 | expect(res).toEqual({ a: 1, b: 20, c: [3, 40] }); 40 | }); 41 | 42 | test('map_modern', () => { 43 | const obj = { a: 1, b: 2, c: [3, 4] }; 44 | const res = new Traverse(obj).map((ctx, x) => { 45 | if (typeof x === 'number' && x % 2 === 0) { 46 | ctx.update(x * 10); 47 | } 48 | }); 49 | 50 | expect(obj).toEqual({ a: 1, b: 2, c: [3, 4] }); 51 | expect(res).toEqual({ a: 1, b: 20, c: [3, 40] }); 52 | }); 53 | 54 | test('clone', () => { 55 | const obj = { a: 1, b: 2, c: [3, 4] }; 56 | const res = traverse(obj).clone(); 57 | expect(obj).toEqual(res); 58 | expect(obj).not.toBe(res); 59 | 60 | obj.a += 1; 61 | expect(res.a).toBe(1); 62 | 63 | obj.c.push(5); 64 | expect(res.c).toEqual([3, 4]); 65 | }); 66 | 67 | test('clone_modern', () => { 68 | const obj = { a: 1, b: 2, c: [3, 4] }; 69 | const res = new Traverse(obj).clone(); 70 | expect(obj).toEqual(res); 71 | expect(obj).not.toBe(res); 72 | 73 | obj.a += 1; 74 | expect(res.a).toBe(1); 75 | 76 | obj.c.push(5); 77 | expect(res.c).toEqual([3, 4]); 78 | }); 79 | 80 | // TODO: Investigate why clone gives a different Uint8Array 81 | test('cloneTypedArray', () => { 82 | const obj = new Uint8Array([1]); 83 | const res = traverse(obj).clone(); 84 | 85 | expect(Array.from(obj)).toEqual(Array.from(res)); 86 | expect(obj).not.toBe(res); 87 | 88 | obj.set([2], 0); 89 | res.set([3], 0); 90 | 91 | expect(obj).toEqual(new Uint8Array([2])); 92 | expect(res).toEqual(new Uint8Array([3])); 93 | }); 94 | 95 | test('cloneTypedArray_modern', () => { 96 | const obj = new Uint8Array([1]); 97 | const res = new Traverse(obj).clone(); 98 | 99 | expect(Array.from(obj)).toEqual(Array.from(res)); 100 | expect(obj).not.toBe(res); 101 | 102 | obj.set([2], 0); 103 | res.set([3], 0); 104 | 105 | expect(obj).toEqual(new Uint8Array([2])); 106 | expect(res).toEqual(new Uint8Array([3])); 107 | }); 108 | 109 | test('reduce', () => { 110 | const obj = { a: 1, b: 2, c: [3, 4] }; 111 | const res = traverse(obj).reduce(function (acc, x) { 112 | if (this.isLeaf) { 113 | acc.push(x); 114 | } 115 | return acc; 116 | }, []); 117 | 118 | expect(obj).toEqual({ a: 1, b: 2, c: [3, 4] }); 119 | expect(res).toEqual([1, 2, 3, 4]); 120 | }); 121 | 122 | test('reduce_modern', () => { 123 | const obj = { a: 1, b: 2, c: [3, 4] }; 124 | const res = new Traverse(obj).reduce((ctx, acc, x) => { 125 | if (ctx.isLeaf) { 126 | acc.push(x); 127 | } 128 | return acc; 129 | }, []); 130 | 131 | expect(obj).toEqual({ a: 1, b: 2, c: [3, 4] }); 132 | expect(res).toEqual([1, 2, 3, 4]); 133 | }); 134 | 135 | test('reduceInit', () => { 136 | const obj = { a: 1, b: 2, c: [3, 4] }; 137 | const res = traverse(obj).reduce(function (acc) { 138 | if (this.isRoot) { 139 | assert.fail('got root'); 140 | } 141 | return acc; 142 | }); 143 | // t.same(obj, { a: 1, b: 2, c: [3, 4] }); 144 | // t.same(res, obj); 145 | expect(obj).toEqual({ a: 1, b: 2, c: [3, 4] }); 146 | expect(res).toEqual(obj); 147 | }); 148 | 149 | test('reduceInit_modern', () => { 150 | const obj = { a: 1, b: 2, c: [3, 4] }; 151 | const res = new Traverse(obj).reduce((ctx, acc) => { 152 | if (ctx.isRoot) { 153 | assert.fail('got root'); 154 | } 155 | return acc; 156 | }); 157 | // t.same(obj, { a: 1, b: 2, c: [3, 4] }); 158 | // t.same(res, obj); 159 | expect(obj).toEqual({ a: 1, b: 2, c: [3, 4] }); 160 | expect(res).toEqual(obj); 161 | }); 162 | 163 | test('remove', () => { 164 | const obj = { a: 1, b: 2, c: [3, 4] }; 165 | traverse(obj).forEach(function (x) { 166 | if (this.isLeaf && x % 2 === 0) { 167 | this.remove(); 168 | } 169 | }); 170 | 171 | expect(obj).toEqual({ a: 1, c: [3] }); 172 | }); 173 | 174 | test('remove_modern', () => { 175 | const obj = { a: 1, b: 2, c: [3, 4] }; 176 | new Traverse(obj).forEach((ctx, x) => { 177 | if (ctx.isLeaf && x % 2 === 0) { 178 | ctx.remove(); 179 | } 180 | }); 181 | 182 | expect(obj).toEqual({ a: 1, c: [3] }); 183 | }); 184 | 185 | test('removeNoStop', () => { 186 | const obj = { a: 1, b: 2, c: { d: 3, e: 4 }, f: 5 }; 187 | 188 | const keys: (PropertyKey | undefined)[] = []; 189 | traverse(obj).forEach(function () { 190 | keys.push(this.key); 191 | if (this.key === 'c') { 192 | this.remove(); 193 | } 194 | }); 195 | 196 | expect(keys).toEqual([undefined, 'a', 'b', 'c', 'd', 'e', 'f']); 197 | }); 198 | 199 | test('removeNoStop_modern', () => { 200 | const obj = { a: 1, b: 2, c: { d: 3, e: 4 }, f: 5 }; 201 | 202 | const keys: (PropertyKey | undefined)[] = []; 203 | new Traverse(obj).forEach((ctx) => { 204 | keys.push(ctx.key); 205 | if (ctx.key === 'c') { 206 | ctx.remove(); 207 | } 208 | }); 209 | 210 | expect(keys).toEqual([undefined, 'a', 'b', 'c', 'd', 'e', 'f']); 211 | }); 212 | 213 | test('removeStop', () => { 214 | const obj = { a: 1, b: 2, c: { d: 3, e: 4 }, f: 5 }; 215 | 216 | const keys: (PropertyKey | undefined)[] = []; 217 | traverse(obj).forEach(function () { 218 | keys.push(this.key); 219 | if (this.key === 'c') { 220 | this.remove(true); 221 | } 222 | }); 223 | 224 | expect(keys).toEqual([undefined, 'a', 'b', 'c', 'f']); 225 | }); 226 | 227 | test('removeStop_modern', () => { 228 | const obj = { a: 1, b: 2, c: { d: 3, e: 4 }, f: 5 }; 229 | 230 | const keys: (PropertyKey | undefined)[] = []; 231 | new Traverse(obj).forEach((ctx) => { 232 | keys.push(ctx.key); 233 | if (ctx.key === 'c') { 234 | ctx.remove(true); 235 | } 236 | }); 237 | 238 | expect(keys).toEqual([undefined, 'a', 'b', 'c', 'f']); 239 | }); 240 | 241 | test('removeMap', () => { 242 | const obj = { a: 1, b: 2, c: [3, 4] }; 243 | const res = traverse(obj).map(function (x) { 244 | if (this.isLeaf && x % 2 === 0) { 245 | this.remove(); 246 | } 247 | }); 248 | 249 | expect(obj).toEqual({ a: 1, b: 2, c: [3, 4] }); 250 | expect(res).toEqual({ a: 1, c: [3] }); 251 | }); 252 | 253 | test('removeMap_modern', () => { 254 | const obj = { a: 1, b: 2, c: [3, 4] }; 255 | const res = new Traverse(obj).map((ctx, x) => { 256 | if (ctx.isLeaf && x % 2 === 0) { 257 | ctx.remove(); 258 | } 259 | }); 260 | 261 | expect(obj).toEqual({ a: 1, b: 2, c: [3, 4] }); 262 | expect(res).toEqual({ a: 1, c: [3] }); 263 | }); 264 | 265 | test('delete', () => { 266 | const obj = { a: 1, b: 2, c: [3, 4] }; 267 | traverse(obj).forEach(function (x) { 268 | if (this.isLeaf && x % 2 === 0) { 269 | this.delete(); 270 | } 271 | }); 272 | 273 | expect(obj).toEqual({ a: 1, c: [3, undefined] }); 274 | 275 | expect(obj).not.toEqual({ a: 1, c: [3, null] }); 276 | }); 277 | 278 | test('delete_modern', () => { 279 | const obj = { a: 1, b: 2, c: [3, 4] }; 280 | new Traverse(obj).forEach((ctx, x) => { 281 | if (ctx.isLeaf && x % 2 === 0) { 282 | ctx.delete(); 283 | } 284 | }); 285 | 286 | expect(obj).toEqual({ a: 1, c: [3, undefined] }); 287 | 288 | expect(obj).not.toEqual({ a: 1, c: [3, null] }); 289 | }); 290 | 291 | test('deleteNoStop', () => { 292 | const obj = { a: 1, b: 2, c: { d: 3, e: 4 } }; 293 | 294 | const keys: (PropertyKey | undefined)[] = []; 295 | traverse(obj).forEach(function () { 296 | keys.push(this.key); 297 | if (this.key === 'c') { 298 | this.delete(); 299 | } 300 | }); 301 | 302 | expect(keys).toEqual([undefined, 'a', 'b', 'c', 'd', 'e']); 303 | }); 304 | 305 | test('deleteNoStop_modern', () => { 306 | const obj = { a: 1, b: 2, c: { d: 3, e: 4 } }; 307 | 308 | const keys: (PropertyKey | undefined)[] = []; 309 | new Traverse(obj).forEach((ctx) => { 310 | keys.push(ctx.key); 311 | if (ctx.key === 'c') { 312 | ctx.delete(); 313 | } 314 | }); 315 | 316 | expect(keys).toEqual([undefined, 'a', 'b', 'c', 'd', 'e']); 317 | }); 318 | 319 | test('deleteStop', () => { 320 | const obj = { a: 1, b: 2, c: { d: 3, e: 4 } }; 321 | 322 | const keys: (PropertyKey | undefined)[] = []; 323 | traverse(obj).forEach(function () { 324 | keys.push(this.key); 325 | if (this.key === 'c') { 326 | this.delete(true); 327 | } 328 | }); 329 | 330 | expect(keys).toEqual([undefined, 'a', 'b', 'c']); 331 | }); 332 | 333 | test('deleteStop_modern', () => { 334 | const obj = { a: 1, b: 2, c: { d: 3, e: 4 } }; 335 | 336 | const keys: (PropertyKey | undefined)[] = []; 337 | new Traverse(obj).forEach((ctx) => { 338 | keys.push(ctx.key); 339 | if (ctx.key === 'c') { 340 | ctx.delete(true); 341 | } 342 | }); 343 | 344 | expect(keys).toEqual([undefined, 'a', 'b', 'c']); 345 | }); 346 | 347 | test('deleteRedux', () => { 348 | const obj = { a: 1, b: 2, c: [3, 4, 5] }; 349 | traverse(obj).forEach(function (x) { 350 | if (this.isLeaf && x % 2 === 0) { 351 | this.delete(); 352 | } 353 | }); 354 | 355 | expect(obj).toEqual({ a: 1, c: [3, undefined, 5] }); 356 | expect(obj).toEqual({ a: 1, c: [3, , 5] }); 357 | expect(obj).not.toEqual({ a: 1, c: [3, null, 5] }); 358 | expect(obj).not.toEqual({ a: 1, c: [3, 5] }); 359 | }); 360 | 361 | test('deleteRedux_modern', () => { 362 | const obj = { a: 1, b: 2, c: [3, 4, 5] }; 363 | new Traverse(obj).forEach((ctx, x) => { 364 | if (ctx.isLeaf && x % 2 === 0) { 365 | ctx.delete(); 366 | } 367 | }); 368 | 369 | expect(obj).toEqual({ a: 1, c: [3, undefined, 5] }); 370 | expect(obj).toEqual({ a: 1, c: [3, , 5] }); 371 | expect(obj).not.toEqual({ a: 1, c: [3, null, 5] }); 372 | expect(obj).not.toEqual({ a: 1, c: [3, 5] }); 373 | }); 374 | 375 | test('deleteMap', () => { 376 | const obj = { a: 1, b: 2, c: [3, 4] }; 377 | const res = traverse(obj).map(function (x) { 378 | if (this.isLeaf && x % 2 === 0) { 379 | this.delete(); 380 | } 381 | }); 382 | 383 | expect(obj).toEqual({ a: 1, b: 2, c: [3, 4] }); 384 | 385 | const xs = [3, 4]; 386 | delete xs[1]; 387 | 388 | expect(res).toEqual({ a: 1, c: xs }); 389 | 390 | expect(res).toEqual({ a: 1, c: [3, ,] }); 391 | expect(res).toEqual({ a: 1, c: [3, undefined] }); 392 | }); 393 | 394 | test('deleteMap_modern', () => { 395 | const obj = { a: 1, b: 2, c: [3, 4] }; 396 | const res = new Traverse(obj).map((ctx, x) => { 397 | if (ctx.isLeaf && x % 2 === 0) { 398 | ctx.delete(); 399 | } 400 | }); 401 | 402 | expect(obj).toEqual({ a: 1, b: 2, c: [3, 4] }); 403 | 404 | const xs = [3, 4]; 405 | delete xs[1]; 406 | 407 | expect(res).toEqual({ a: 1, c: xs }); 408 | 409 | expect(res).toEqual({ a: 1, c: [3, ,] }); 410 | expect(res).toEqual({ a: 1, c: [3, undefined] }); 411 | }); 412 | 413 | test('deleteMapRedux', () => { 414 | const obj = { a: 1, b: 2, c: [3, 4, 5] }; 415 | const res = traverse(obj).map(function (x) { 416 | if (this.isLeaf && x % 2 === 0) { 417 | this.delete(); 418 | } 419 | }); 420 | 421 | expect(obj).toEqual({ a: 1, b: 2, c: [3, 4, 5] }); 422 | 423 | const xs = [3, 4, 5]; 424 | delete xs[1]; 425 | 426 | // t.ok(deepEqual(res, { a: 1, c: xs })); 427 | // t.ok(!deepEqual(res, { a: 1, c: [3, 5] })); 428 | // t.ok(deepEqual(res, { a: 1, c: [3, , 5] })); 429 | expect(res).toEqual({ a: 1, c: xs }); 430 | expect(res).toEqual({ a: 1, c: [3, , 5] }); 431 | expect(res).toEqual({ a: 1, c: [3, , 5] }); 432 | }); 433 | 434 | test('deleteMapRedux_modern', () => { 435 | const obj = { a: 1, b: 2, c: [3, 4, 5] }; 436 | const res = new Traverse(obj).map((ctx, x) => { 437 | if (ctx.isLeaf && x % 2 === 0) { 438 | ctx.delete(); 439 | } 440 | }); 441 | 442 | expect(obj).toEqual({ a: 1, b: 2, c: [3, 4, 5] }); 443 | 444 | const xs = [3, 4, 5]; 445 | delete xs[1]; 446 | 447 | // t.ok(deepEqual(res, { a: 1, c: xs })); 448 | // t.ok(!deepEqual(res, { a: 1, c: [3, 5] })); 449 | // t.ok(deepEqual(res, { a: 1, c: [3, , 5] })); 450 | expect(res).toEqual({ a: 1, c: xs }); 451 | expect(res).toEqual({ a: 1, c: [3, , 5] }); 452 | expect(res).toEqual({ a: 1, c: [3, , 5] }); 453 | }); 454 | 455 | test('objectToString', () => { 456 | const obj = { a: 1, b: 2, c: [3, 4] }; 457 | const res = traverse(obj).forEach(function (x) { 458 | if (typeof x === 'object' && !this.isRoot) { 459 | this.update(JSON.stringify(x)); 460 | } 461 | }); 462 | 463 | expect(obj).toEqual(res); 464 | expect(obj).toEqual({ a: 1, b: 2, c: '[3,4]' }); 465 | }); 466 | 467 | test('objectToString_modern', () => { 468 | const obj = { a: 1, b: 2, c: [3, 4] }; 469 | const res = new Traverse(obj).forEach((ctx, x) => { 470 | if (typeof x === 'object' && !ctx.isRoot) { 471 | ctx.update(JSON.stringify(x)); 472 | } 473 | }); 474 | 475 | expect(obj).toEqual(res); 476 | expect(obj).toEqual({ a: 1, b: 2, c: '[3,4]' }); 477 | }); 478 | 479 | test('stringToObject', () => { 480 | const obj = { a: 1, b: 2, c: '[3,4]' }; 481 | const res = traverse(obj).forEach(function (x) { 482 | if (typeof x === 'string') { 483 | this.update(JSON.parse(x)); 484 | } else if (typeof x === 'number' && x % 2 === 0) { 485 | this.update(x * 10); 486 | } 487 | }); 488 | 489 | expect(obj).toEqual(res); 490 | expect(obj).toEqual({ a: 1, b: 20, c: [3, 40] }); 491 | }); 492 | 493 | test('stringToObject_modern', () => { 494 | const obj = { a: 1, b: 2, c: '[3,4]' }; 495 | const res = new Traverse(obj).forEach((ctx, x) => { 496 | if (typeof x === 'string') { 497 | ctx.update(JSON.parse(x)); 498 | } else if (typeof x === 'number' && x % 2 === 0) { 499 | ctx.update(x * 10); 500 | } 501 | }); 502 | 503 | expect(obj).toEqual(res); 504 | expect(obj).toEqual({ a: 1, b: 20, c: [3, 40] }); 505 | }); 506 | -------------------------------------------------------------------------------- /src/modern.ts: -------------------------------------------------------------------------------- 1 | type TypedArray = 2 | | Int8Array 3 | | Uint8Array 4 | | Uint8ClampedArray 5 | | Int16Array 6 | | Uint16Array 7 | | Int32Array 8 | | Uint32Array 9 | | Float32Array 10 | | Float64Array 11 | | BigInt64Array 12 | | BigUint64Array; 13 | 14 | export interface TraverseOptions { 15 | /** 16 | * If true, does not alter the original object 17 | */ 18 | immutable?: boolean; 19 | 20 | /** 21 | * If false, removes all symbols from traversed objects 22 | * 23 | * @default false 24 | */ 25 | includeSymbols?: boolean; 26 | } 27 | 28 | export interface TraverseContext { 29 | /** 30 | * The present node on the recursive walk 31 | */ 32 | node: any; 33 | 34 | /** 35 | * An array of string keys from the root to the present node 36 | */ 37 | path: PropertyKey[]; 38 | 39 | /** 40 | * The context of the node's parent. 41 | * This is `undefined` for the root node. 42 | */ 43 | parent: TraverseContext | undefined; 44 | 45 | /** 46 | * The contexts of the node's parents. 47 | */ 48 | parents: TraverseContext[]; 49 | 50 | /** 51 | * The name of the key of the present node in its parent. 52 | * This is `undefined` for the root node. 53 | */ 54 | key: PropertyKey | undefined; 55 | 56 | /** 57 | * Whether the present node is the root node 58 | */ 59 | isRoot: boolean; 60 | /** 61 | * Whether the present node is not the root node 62 | */ 63 | notRoot: boolean; 64 | 65 | /** 66 | * Whether the present node is the last node 67 | */ 68 | isLast: boolean; 69 | 70 | /** 71 | * Whether the present node is the first node 72 | */ 73 | isFirst: boolean; 74 | 75 | /** 76 | * Whether or not the present node is a leaf node (has no children) 77 | */ 78 | isLeaf: boolean; 79 | /** 80 | * Whether or not the present node is not a leaf node (has children) 81 | */ 82 | notLeaf: boolean; 83 | 84 | /** 85 | * Depth of the node within the traversal 86 | */ 87 | level: number; 88 | 89 | /** 90 | * If the node equals one of its parents, the `circular` attribute is set to the context of that parent and the traversal progresses no deeper. 91 | */ 92 | circular: TraverseContext | undefined; 93 | 94 | /** 95 | * Set a new value for the present node. 96 | * 97 | * All the elements in `value` will be recursively traversed unless `stopHere` is true (false by default). 98 | */ 99 | update(value: any, stopHere?: boolean): void; 100 | 101 | /** 102 | * Remove the current element from the output. If the node is in an Array it will be spliced off. Otherwise it will be deleted from its parent. 103 | */ 104 | remove(stopHere?: boolean): void; 105 | 106 | /** 107 | * Delete the current element from its parent in the output. Calls `delete` even on Arrays. 108 | */ 109 | delete(stopHere?: boolean): void; 110 | 111 | /** 112 | * Object keys of the node. 113 | */ 114 | keys: PropertyKey[] | null; 115 | 116 | /** 117 | * Call this function before all of the children are traversed. 118 | * You can assign into `ctx.keys` here to traverse in a custom order. 119 | */ 120 | before(callback: (ctx: TraverseContext, value: any) => void): void; 121 | 122 | /** 123 | * Call this function after all of the children are traversed. 124 | */ 125 | after(callback: (ctx: TraverseContext, value: any) => void): void; 126 | 127 | /** 128 | * Call this function before each of the children are traversed. 129 | */ 130 | pre(callback: (ctx: TraverseContext, child: any, key: any) => void): void; 131 | 132 | /** 133 | * Call this function after each of the children are traversed. 134 | */ 135 | post(callback: (ctx: TraverseContext, child: any) => void): void; 136 | 137 | /** 138 | * Stops traversal entirely. 139 | */ 140 | stop(): void; 141 | 142 | /** 143 | * Prevents traversing descendents of the current node. 144 | */ 145 | block(): void; 146 | } 147 | 148 | const to_string = (obj: unknown) => Object.prototype.toString.call(obj); 149 | 150 | const is_typed_array = (value: unknown): value is TypedArray => 151 | ArrayBuffer.isView(value) && !(value instanceof DataView); 152 | const is_date = (obj: unknown): obj is Date => to_string(obj) === '[object Date]'; 153 | const is_regexp = (obj: unknown): obj is RegExp => to_string(obj) === '[object RegExp]'; 154 | const is_error = (obj: unknown): obj is Error => to_string(obj) === '[object Error]'; 155 | const is_boolean = (obj: unknown): obj is boolean => to_string(obj) === '[object Boolean]'; 156 | const is_number = (obj: unknown): obj is number => to_string(obj) === '[object Number]'; 157 | const is_string = (obj: unknown): obj is string => to_string(obj) === '[object String]'; 158 | const is_array = Array.isArray; 159 | 160 | const gopd = Object.getOwnPropertyDescriptor; 161 | const is_property_enumerable = Object.prototype.propertyIsEnumerable; 162 | const get_own_property_symbols = Object.getOwnPropertySymbols; 163 | const has_own_property = Object.prototype.hasOwnProperty; 164 | const object_keys = Object.keys; 165 | 166 | function own_enumerable_keys(obj: object): PropertyKey[] { 167 | const res: PropertyKey[] = object_keys(obj); 168 | 169 | const symbols = get_own_property_symbols(obj); 170 | for (let i = 0; i < symbols.length; i++) { 171 | if (is_property_enumerable.call(obj, symbols[i])) { 172 | res.push(symbols[i]); 173 | } 174 | } 175 | 176 | return res; 177 | } 178 | 179 | function is_writable(object: any, key: PropertyKey) { 180 | return !gopd(object, key)?.writable; 181 | } 182 | 183 | function copy(src: any, options: TraverseOptions) { 184 | if (typeof src === 'object' && src !== null) { 185 | let dst: any; 186 | 187 | if (is_array(src)) { 188 | dst = []; 189 | } else if (is_date(src)) { 190 | dst = new Date(src.getTime ? src.getTime() : src); 191 | } else if (is_regexp(src)) { 192 | dst = new RegExp(src); 193 | } else if (is_error(src)) { 194 | dst = { message: src.message }; 195 | } else if (is_boolean(src) || is_number(src) || is_string(src)) { 196 | dst = Object(src); 197 | } else if (is_typed_array(src)) { 198 | return src.slice(); 199 | } else { 200 | dst = Object.create(Object.getPrototypeOf(src)); 201 | } 202 | 203 | const iterator_function = options.includeSymbols ? own_enumerable_keys : object_keys; 204 | for (const key of iterator_function(src)) { 205 | dst[key] = src[key]; 206 | } 207 | 208 | return dst; 209 | } 210 | 211 | return src; 212 | } 213 | 214 | const empty_null: TraverseOptions = { 215 | includeSymbols: false, 216 | immutable: false, 217 | }; 218 | 219 | function walk( 220 | root: any, 221 | cb: (ctx: TraverseContext, v: any) => void, 222 | options: TraverseOptions = empty_null, 223 | ) { 224 | const path: PropertyKey[] = []; 225 | const parents: any[] = []; 226 | let alive = true; 227 | 228 | const iterator_function = options.includeSymbols ? own_enumerable_keys : object_keys; 229 | const immutable = !!options.immutable; 230 | 231 | return (function walker(node_) { 232 | const node = immutable ? copy(node_, options) : node_; 233 | const modifiers = {} as { 234 | before?: (ctx: TraverseContext, value: any) => void; 235 | after?: (ctx: TraverseContext, value: any) => void; 236 | pre?: (ctx: TraverseContext, child: any, key: any) => void; 237 | post?: (ctx: TraverseContext, child: any) => void; 238 | stop?: () => void; 239 | }; 240 | 241 | let keep_going = true; 242 | 243 | const state = { 244 | node, 245 | node_, 246 | path: ([] as any[]).concat(path) as PropertyKey[], 247 | parent: parents[parents.length - 1], 248 | parents, 249 | key: path[path.length - 1], 250 | isRoot: path.length === 0, 251 | level: path.length, 252 | circular: undefined, 253 | isLeaf: false as boolean, 254 | notLeaf: true as boolean, 255 | notRoot: true as boolean, 256 | isFirst: false as boolean, 257 | isLast: false as boolean, 258 | update: function (x: any, stopHere: boolean = false) { 259 | if (!state.isRoot) { 260 | state.parent.node[state.key] = x; 261 | } 262 | state.node = x; 263 | if (stopHere) { 264 | keep_going = false; 265 | } 266 | }, 267 | delete: function (stopHere: boolean) { 268 | delete state.parent.node[state.key]; 269 | if (stopHere) { 270 | keep_going = false; 271 | } 272 | }, 273 | remove: function (stopHere: boolean) { 274 | if (is_array(state.parent.node)) { 275 | state.parent.node.splice(state.key, 1); 276 | } else { 277 | delete state.parent.node[state.key]; 278 | } 279 | if (stopHere) { 280 | keep_going = false; 281 | } 282 | }, 283 | keys: null as PropertyKey[] | null, 284 | before: function (f: (ctx: TraverseContext, value: any) => void) { 285 | modifiers.before = f; 286 | }, 287 | after: function (f: (ctx: TraverseContext, value: any) => void) { 288 | modifiers.after = f; 289 | }, 290 | pre: function (f: (ctx: TraverseContext, child: any, key: any) => void) { 291 | modifiers.pre = f; 292 | }, 293 | post: function (f: (ctx: TraverseContext, child: any) => void) { 294 | modifiers.post = f; 295 | }, 296 | stop: function () { 297 | alive = false; 298 | }, 299 | block: function () { 300 | keep_going = false; 301 | }, 302 | } satisfies TraverseContext & { node_: any }; 303 | 304 | if (!alive) { 305 | return state; 306 | } 307 | 308 | function update_state() { 309 | if (typeof state.node === 'object' && state.node !== null) { 310 | if (!state.keys || state.node_ !== state.node) { 311 | state.keys = iterator_function(state.node); 312 | } 313 | 314 | state.isLeaf = state.keys.length === 0; 315 | 316 | for (let i = 0; i < parents.length; i++) { 317 | if (parents[i].node_ === node_) { 318 | state.circular = parents[i]; 319 | break; 320 | } 321 | } 322 | } else { 323 | state.isLeaf = true; 324 | state.keys = null; 325 | } 326 | 327 | state.notLeaf = !state.isLeaf; 328 | state.notRoot = !state.isRoot; 329 | } 330 | 331 | update_state(); 332 | 333 | // use return values to update if defined 334 | const ret = cb(state, state.node); 335 | if (ret !== undefined && state.update) { 336 | state.update(ret); 337 | } 338 | 339 | if (modifiers.before) { 340 | modifiers.before(state, state.node); 341 | } 342 | 343 | if (!keep_going) { 344 | return state; 345 | } 346 | 347 | if (typeof state.node === 'object' && state.node !== null && !state.circular) { 348 | parents.push(state); 349 | 350 | update_state(); 351 | 352 | for (const [index, key] of Object.entries(state.keys ?? [])) { 353 | path.push(key); 354 | 355 | if (modifiers.pre) { 356 | modifiers.pre(state, state.node[key], key); 357 | } 358 | 359 | const child = walker(state.node[key]); 360 | if (immutable && has_own_property.call(state.node, key) && !is_writable(state.node, key)) { 361 | state.node[key] = child.node; 362 | } 363 | 364 | child.isLast = state.keys?.length ? +index === state.keys.length - 1 : false; 365 | child.isFirst = +index === 0; 366 | 367 | if (modifiers.post) { 368 | modifiers.post(state, child); 369 | } 370 | 371 | path.pop(); 372 | } 373 | parents.pop(); 374 | } 375 | 376 | if (modifiers.after) { 377 | modifiers.after(state, state.node); 378 | } 379 | 380 | return state; 381 | })(root).node; 382 | } 383 | 384 | export class Traverse { 385 | #value: any; 386 | #options: TraverseOptions; 387 | 388 | constructor(obj: any, options: TraverseOptions = empty_null) { 389 | this.#value = obj; 390 | this.#options = options; 391 | } 392 | 393 | /** 394 | * Get the element at the array `path`. 395 | */ 396 | get(paths: PropertyKey[]): any { 397 | let node = this.#value; 398 | 399 | for (let i = 0; node && i < paths.length; i++) { 400 | const key = paths[i]; 401 | 402 | if ( 403 | !has_own_property.call(node, key) || 404 | (!this.#options.includeSymbols && typeof key === 'symbol') 405 | ) { 406 | return void undefined; 407 | } 408 | 409 | node = node[key]; 410 | } 411 | 412 | return node; 413 | } 414 | 415 | /** 416 | * Return whether the element at the array `path` exists. 417 | */ 418 | has(paths: PropertyKey[]): boolean { 419 | let node = this.#value; 420 | 421 | for (let i = 0; node && i < paths.length; i++) { 422 | const key = paths[i]; 423 | 424 | if ( 425 | !has_own_property.call(node, key) || 426 | (!this.#options.includeSymbols && typeof key === 'symbol') 427 | ) { 428 | return false; 429 | } 430 | 431 | node = node[key]; 432 | } 433 | 434 | return true; 435 | } 436 | 437 | /** 438 | * Set the element at the array `path` to `value`. 439 | */ 440 | set(path: PropertyKey[], value: any): any { 441 | let node = this.#value; 442 | 443 | let i = 0; 444 | for (i = 0; i < path.length - 1; i++) { 445 | const key = path[i]; 446 | 447 | if (!has_own_property.call(node, key)) { 448 | node[key] = {}; 449 | } 450 | 451 | node = node[key]; 452 | } 453 | 454 | node[path[i]] = value; 455 | 456 | return value; 457 | } 458 | 459 | /** 460 | * Execute `fn` for each node in the object and return a new object with the results of the walk. To update nodes in the result use `this.update(value)`. 461 | */ 462 | map(cb: (ctx: TraverseContext, v: any) => void): any { 463 | return walk(this.#value, cb, { 464 | immutable: true, 465 | includeSymbols: !!this.#options.includeSymbols, 466 | }); 467 | } 468 | 469 | /** 470 | * Execute `fn` for each node in the object but unlike `.map()`, when `this.update()` is called it updates the object in-place. 471 | */ 472 | forEach(cb: (ctx: TraverseContext, v: any) => void): any { 473 | this.#value = walk(this.#value, cb, this.#options); 474 | return this.#value; 475 | } 476 | 477 | /** 478 | * For each node in the object, perform a [left-fold](http://en.wikipedia.org/wiki/Fold_(higher-order_function)) with the return value of `fn(acc, node)`. 479 | * 480 | * If `init` isn't specified, `init` is set to the root object for the first step and the root element is skipped. 481 | */ 482 | reduce(cb: (ctx: TraverseContext, acc: any, v: any) => void, init?: any): any { 483 | const skip = arguments.length === 1; 484 | let acc = skip ? this.#value : init; 485 | 486 | this.forEach((ctx, x) => { 487 | if (!ctx.isRoot || !skip) { 488 | acc = cb(ctx, acc, x); 489 | } 490 | }); 491 | 492 | return acc; 493 | } 494 | 495 | /** 496 | * Return an `Array` of every possible non-cyclic path in the object. 497 | * Paths are `Array`s of string keys. 498 | */ 499 | paths(): PropertyKey[][] { 500 | const acc: PropertyKey[][] = []; 501 | 502 | this.forEach((ctx) => { 503 | acc.push(ctx.path); 504 | }); 505 | 506 | return acc; 507 | } 508 | 509 | /** 510 | * Return an `Array` of every node in the object. 511 | */ 512 | nodes(): any[] { 513 | const acc: any[] = []; 514 | 515 | this.forEach((ctx) => { 516 | acc.push(ctx.node); 517 | }); 518 | 519 | return acc; 520 | } 521 | 522 | /** 523 | * Create a deep clone of the object. 524 | */ 525 | clone(): any { 526 | const parents: any[] = []; 527 | const nodes: any[] = []; 528 | const options = this.#options; 529 | 530 | if (is_typed_array(this.#value)) { 531 | return this.#value.slice(); 532 | } 533 | 534 | return (function clone(src) { 535 | for (let i = 0; i < parents.length; i++) { 536 | if (parents[i] === src) { 537 | return nodes[i]; 538 | } 539 | } 540 | 541 | if (typeof src === 'object' && src !== null) { 542 | const dst = copy(src, options); 543 | 544 | parents.push(src); 545 | nodes.push(dst); 546 | 547 | const iteratorFunction = options.includeSymbols ? own_enumerable_keys : object_keys; 548 | for (const key of iteratorFunction(src)) { 549 | dst[key] = clone(src[key]); 550 | } 551 | 552 | parents.pop(); 553 | nodes.pop(); 554 | return dst; 555 | } 556 | 557 | return src; 558 | })(this.#value); 559 | } 560 | } 561 | -------------------------------------------------------------------------------- /src/index.ts: -------------------------------------------------------------------------------- 1 | type TypedArray = 2 | | Int8Array 3 | | Uint8Array 4 | | Uint8ClampedArray 5 | | Int16Array 6 | | Uint16Array 7 | | Int32Array 8 | | Uint32Array 9 | | Float32Array 10 | | Float64Array 11 | | BigInt64Array 12 | | BigUint64Array; 13 | 14 | export interface TraverseOptions { 15 | /** 16 | * If true, does not alter the original object 17 | */ 18 | immutable?: boolean; 19 | 20 | /** 21 | * If false, removes all symbols from traversed objects 22 | * 23 | * @default false 24 | */ 25 | includeSymbols?: boolean; 26 | } 27 | 28 | export interface TraverseContext { 29 | /** 30 | * The present node on the recursive walk 31 | */ 32 | node: any; 33 | 34 | /** 35 | * An array of string keys from the root to the present node 36 | */ 37 | path: PropertyKey[]; 38 | 39 | /** 40 | * The context of the node's parent. 41 | * This is `undefined` for the root node. 42 | */ 43 | parent: TraverseContext | undefined; 44 | 45 | /** 46 | * The contexts of the node's parents. 47 | */ 48 | parents: TraverseContext[]; 49 | 50 | /** 51 | * The name of the key of the present node in its parent. 52 | * This is `undefined` for the root node. 53 | */ 54 | key: PropertyKey | undefined; 55 | 56 | /** 57 | * Whether the present node is the root node 58 | */ 59 | isRoot: boolean; 60 | /** 61 | * Whether the present node is not the root node 62 | */ 63 | notRoot: boolean; 64 | 65 | /** 66 | * Whether the present node is the last node 67 | */ 68 | isLast: boolean; 69 | 70 | /** 71 | * Whether the present node is the first node 72 | */ 73 | isFirst: boolean; 74 | 75 | /** 76 | * Whether or not the present node is a leaf node (has no children) 77 | */ 78 | isLeaf: boolean; 79 | /** 80 | * Whether or not the present node is not a leaf node (has children) 81 | */ 82 | notLeaf: boolean; 83 | 84 | /** 85 | * Depth of the node within the traversal 86 | */ 87 | level: number; 88 | 89 | /** 90 | * If the node equals one of its parents, the `circular` attribute is set to the context of that parent and the traversal progresses no deeper. 91 | */ 92 | circular: TraverseContext | undefined; 93 | 94 | /** 95 | * Set a new value for the present node. 96 | * 97 | * All the elements in `value` will be recursively traversed unless `stopHere` is true (false by default). 98 | */ 99 | update(value: any, stopHere?: boolean): void; 100 | 101 | /** 102 | * Remove the current element from the output. If the node is in an Array it will be spliced off. Otherwise it will be deleted from its parent. 103 | */ 104 | remove(stopHere?: boolean): void; 105 | 106 | /** 107 | * Delete the current element from its parent in the output. Calls `delete` even on Arrays. 108 | */ 109 | delete(stopHere?: boolean): void; 110 | 111 | /** 112 | * Object keys of the node. 113 | */ 114 | keys: PropertyKey[] | null; 115 | 116 | /** 117 | * Call this function before all of the children are traversed. 118 | * You can assign into `this.keys` here to traverse in a custom order. 119 | */ 120 | before(callback: (this: TraverseContext, value: any) => void): void; 121 | 122 | /** 123 | * Call this function after all of the children are traversed. 124 | */ 125 | after(callback: (this: TraverseContext, value: any) => void): void; 126 | 127 | /** 128 | * Call this function before each of the children are traversed. 129 | */ 130 | pre(callback: (this: TraverseContext, child: any, key: any) => void): void; 131 | 132 | /** 133 | * Call this function after each of the children are traversed. 134 | */ 135 | post(callback: (this: TraverseContext, child: any) => void): void; 136 | 137 | /** 138 | * Stops traversal entirely. 139 | */ 140 | stop(): void; 141 | 142 | /** 143 | * Prevents traversing descendents of the current node. 144 | */ 145 | block(): void; 146 | } 147 | 148 | const to_string = (obj: unknown) => Object.prototype.toString.call(obj); 149 | 150 | const is_typed_array = (value: unknown): value is TypedArray => 151 | ArrayBuffer.isView(value) && !(value instanceof DataView); 152 | const is_date = (obj: unknown): obj is Date => to_string(obj) === '[object Date]'; 153 | const is_regexp = (obj: unknown): obj is RegExp => to_string(obj) === '[object RegExp]'; 154 | const is_error = (obj: unknown): obj is Error => to_string(obj) === '[object Error]'; 155 | const is_boolean = (obj: unknown): obj is boolean => to_string(obj) === '[object Boolean]'; 156 | const is_number = (obj: unknown): obj is number => to_string(obj) === '[object Number]'; 157 | const is_string = (obj: unknown): obj is string => to_string(obj) === '[object String]'; 158 | const is_array = Array.isArray; 159 | 160 | const gopd = Object.getOwnPropertyDescriptor; 161 | const is_property_enumerable = Object.prototype.propertyIsEnumerable; 162 | const get_own_property_symbols = Object.getOwnPropertySymbols; 163 | const has_own_property = Object.prototype.hasOwnProperty; 164 | 165 | function own_enumerable_keys(obj: object): PropertyKey[] { 166 | const res: PropertyKey[] = Object.keys(obj); 167 | 168 | const symbols = get_own_property_symbols(obj); 169 | for (let i = 0; i < symbols.length; i++) { 170 | if (is_property_enumerable.call(obj, symbols[i])) { 171 | res.push(symbols[i]); 172 | } 173 | } 174 | 175 | return res; 176 | } 177 | 178 | function is_writable(object: any, key: PropertyKey) { 179 | return !gopd(object, key)?.writable; 180 | } 181 | 182 | function copy(src: any, options: TraverseOptions) { 183 | if (typeof src === 'object' && src !== null) { 184 | let dst: any; 185 | 186 | if (is_array(src)) { 187 | dst = []; 188 | } else if (is_date(src)) { 189 | dst = new Date(src.getTime ? src.getTime() : src); 190 | } else if (is_regexp(src)) { 191 | dst = new RegExp(src); 192 | } else if (is_error(src)) { 193 | dst = { message: src.message }; 194 | } else if (is_boolean(src) || is_number(src) || is_string(src)) { 195 | dst = Object(src); 196 | } else if (is_typed_array(src)) { 197 | return src.slice(); 198 | } else { 199 | dst = Object.create(Object.getPrototypeOf(src)); 200 | } 201 | 202 | const iterator_function = options.includeSymbols ? own_enumerable_keys : Object.keys; 203 | for (const key of iterator_function(src)) { 204 | dst[key] = src[key]; 205 | } 206 | 207 | return dst; 208 | } 209 | 210 | return src; 211 | } 212 | 213 | const empty_null: TraverseOptions = { 214 | includeSymbols: false, 215 | immutable: false, 216 | }; 217 | 218 | function walk( 219 | root: any, 220 | cb: (this: TraverseContext, v: any) => void, 221 | options: TraverseOptions = empty_null, 222 | ) { 223 | const path: PropertyKey[] = []; 224 | const parents: any[] = []; 225 | let alive = true; 226 | 227 | const iterator_function = options.includeSymbols ? own_enumerable_keys : Object.keys; 228 | const immutable = !!options.immutable; 229 | 230 | return (function walker(node_) { 231 | const node = immutable ? copy(node_, options) : node_; 232 | const modifiers = {} as { 233 | before?: (this: TraverseContext, value: any) => void; 234 | after?: (this: TraverseContext, value: any) => void; 235 | pre?: (this: TraverseContext, child: any, key: any) => void; 236 | post?: (this: TraverseContext, child: any) => void; 237 | stop?: () => void; 238 | }; 239 | 240 | let keep_going = true; 241 | 242 | const state = { 243 | node, 244 | node_, 245 | path: ([] as any[]).concat(path) as PropertyKey[], 246 | parent: parents[parents.length - 1], 247 | parents, 248 | key: path[path.length - 1], 249 | isRoot: path.length === 0, 250 | level: path.length, 251 | circular: undefined, 252 | isLeaf: false as boolean, 253 | notLeaf: true as boolean, 254 | notRoot: true as boolean, 255 | isFirst: false as boolean, 256 | isLast: false as boolean, 257 | update: function (x: any, stopHere: boolean = false) { 258 | if (!state.isRoot) { 259 | state.parent.node[state.key] = x; 260 | } 261 | state.node = x; 262 | if (stopHere) { 263 | keep_going = false; 264 | } 265 | }, 266 | delete: function (stopHere: boolean) { 267 | delete state.parent.node[state.key]; 268 | if (stopHere) { 269 | keep_going = false; 270 | } 271 | }, 272 | remove: function (stopHere: boolean) { 273 | if (is_array(state.parent.node)) { 274 | state.parent.node.splice(state.key, 1); 275 | } else { 276 | delete state.parent.node[state.key]; 277 | } 278 | if (stopHere) { 279 | keep_going = false; 280 | } 281 | }, 282 | keys: null as PropertyKey[] | null, 283 | before: function (f: (this: TraverseContext, value: any) => void) { 284 | modifiers.before = f; 285 | }, 286 | after: function (f: (this: TraverseContext, value: any) => void) { 287 | modifiers.after = f; 288 | }, 289 | pre: function (f: (this: TraverseContext, child: any, key: any) => void) { 290 | modifiers.pre = f; 291 | }, 292 | post: function (f: (this: TraverseContext, child: any) => void) { 293 | modifiers.post = f; 294 | }, 295 | stop: function () { 296 | alive = false; 297 | }, 298 | block: function () { 299 | keep_going = false; 300 | }, 301 | } satisfies TraverseContext & { node_: any }; 302 | 303 | if (!alive) { 304 | return state; 305 | } 306 | 307 | function update_state() { 308 | if (typeof state.node === 'object' && state.node !== null) { 309 | if (!state.keys || state.node_ !== state.node) { 310 | state.keys = iterator_function(state.node); 311 | } 312 | 313 | state.isLeaf = state.keys.length === 0; 314 | 315 | for (let i = 0; i < parents.length; i++) { 316 | if (parents[i].node_ === node_) { 317 | state.circular = parents[i]; 318 | break; 319 | } 320 | } 321 | } else { 322 | state.isLeaf = true; 323 | state.keys = null; 324 | } 325 | 326 | state.notLeaf = !state.isLeaf; 327 | state.notRoot = !state.isRoot; 328 | } 329 | 330 | update_state(); 331 | 332 | // use return values to update if defined 333 | const ret = cb.call(state, state.node); 334 | if (ret !== undefined && state.update) { 335 | state.update(ret); 336 | } 337 | 338 | if (modifiers.before) { 339 | modifiers.before.call(state, state.node); 340 | } 341 | 342 | if (!keep_going) { 343 | return state; 344 | } 345 | 346 | if (typeof state.node === 'object' && state.node !== null && !state.circular) { 347 | parents.push(state); 348 | 349 | update_state(); 350 | 351 | for (const [index, key] of Object.entries(state.keys ?? [])) { 352 | path.push(key); 353 | 354 | if (modifiers.pre) { 355 | modifiers.pre.call(state, state.node[key], key); 356 | } 357 | 358 | const child = walker(state.node[key]); 359 | if (immutable && has_own_property.call(state.node, key) && !is_writable(state.node, key)) { 360 | state.node[key] = child.node; 361 | } 362 | 363 | child.isLast = state.keys?.length ? +index === state.keys.length - 1 : false; 364 | child.isFirst = +index === 0; 365 | 366 | if (modifiers.post) { 367 | modifiers.post.call(state, child); 368 | } 369 | 370 | path.pop(); 371 | } 372 | parents.pop(); 373 | } 374 | 375 | if (modifiers.after) { 376 | modifiers.after.call(state, state.node); 377 | } 378 | 379 | return state; 380 | })(root).node; 381 | } 382 | 383 | /** @deprecated Import `Traverse` from `neotraverse/modern` instead */ 384 | export class Traverse { 385 | // ! Have to keep these public as legacy mode requires them 386 | #value: any; 387 | #options: TraverseOptions; 388 | 389 | constructor(obj: any, options: TraverseOptions = empty_null) { 390 | this.#value = obj; 391 | this.#options = options; 392 | } 393 | 394 | /** 395 | * Get the element at the array `path`. 396 | */ 397 | get(paths: PropertyKey[]): any { 398 | let node = this.#value; 399 | 400 | for (let i = 0; node && i < paths.length; i++) { 401 | const key = paths[i]; 402 | 403 | if ( 404 | !has_own_property.call(node, key) || 405 | (!this.#options.includeSymbols && typeof key === 'symbol') 406 | ) { 407 | return void undefined; 408 | } 409 | 410 | node = node[key]; 411 | } 412 | 413 | return node; 414 | } 415 | 416 | /** 417 | * Return whether the element at the array `path` exists. 418 | */ 419 | has(paths: PropertyKey[]): boolean { 420 | let node = this.#value; 421 | 422 | for (let i = 0; node && i < paths.length; i++) { 423 | const key = paths[i]; 424 | 425 | if ( 426 | !has_own_property.call(node, key) || 427 | (!this.#options.includeSymbols && typeof key === 'symbol') 428 | ) { 429 | return false; 430 | } 431 | 432 | node = node[key]; 433 | } 434 | 435 | return true; 436 | } 437 | 438 | /** 439 | * Set the element at the array `path` to `value`. 440 | */ 441 | set(path: PropertyKey[], value: any): any { 442 | let node = this.#value; 443 | 444 | let i = 0; 445 | for (i = 0; i < path.length - 1; i++) { 446 | const key = path[i]; 447 | 448 | if (!has_own_property.call(node, key)) { 449 | node[key] = {}; 450 | } 451 | 452 | node = node[key]; 453 | } 454 | 455 | node[path[i]] = value; 456 | 457 | return value; 458 | } 459 | 460 | /** 461 | * Execute `fn` for each node in the object and return a new object with the results of the walk. To update nodes in the result use `this.update(value)`. 462 | */ 463 | map(cb: (this: TraverseContext, v: any) => void): any { 464 | return walk(this.#value, cb, { 465 | immutable: true, 466 | includeSymbols: !!this.#options.includeSymbols, 467 | }); 468 | } 469 | 470 | /** 471 | * Execute `fn` for each node in the object but unlike `.map()`, when `this.update()` is called it updates the object in-place. 472 | */ 473 | forEach(cb: (this: TraverseContext, v: any) => void): any { 474 | this.#value = walk(this.#value, cb, this.#options); 475 | return this.#value; 476 | } 477 | 478 | /** 479 | * For each node in the object, perform a [left-fold](http://en.wikipedia.org/wiki/Fold_(higher-order_function)) with the return value of `fn(acc, node)`. 480 | * 481 | * If `init` isn't specified, `init` is set to the root object for the first step and the root element is skipped. 482 | */ 483 | reduce(cb: (this: TraverseContext, acc: any, v: any) => void, init?: any): any { 484 | const skip = arguments.length === 1; 485 | let acc = skip ? this.#value : init; 486 | 487 | this.forEach(function (x) { 488 | if (!this.isRoot || !skip) { 489 | acc = cb.call(this, acc, x); 490 | } 491 | }); 492 | 493 | return acc; 494 | } 495 | 496 | /** 497 | * Return an `Array` of every possible non-cyclic path in the object. 498 | * Paths are `Array`s of string keys. 499 | */ 500 | paths(): PropertyKey[][] { 501 | const acc: PropertyKey[][] = []; 502 | 503 | this.forEach(function () { 504 | acc.push(this.path); 505 | }); 506 | 507 | return acc; 508 | } 509 | 510 | /** 511 | * Return an `Array` of every node in the object. 512 | */ 513 | nodes(): any[] { 514 | const acc: any[] = []; 515 | 516 | this.forEach(function () { 517 | acc.push(this.node); 518 | }); 519 | 520 | return acc; 521 | } 522 | 523 | /** 524 | * Create a deep clone of the object. 525 | */ 526 | clone(): any { 527 | const parents: any[] = []; 528 | const nodes: any[] = []; 529 | const options = this.#options; 530 | 531 | if (is_typed_array(this.#value)) { 532 | return this.#value.slice(); 533 | } 534 | 535 | return (function clone(src) { 536 | for (let i = 0; i < parents.length; i++) { 537 | if (parents[i] === src) { 538 | return nodes[i]; 539 | } 540 | } 541 | 542 | if (typeof src === 'object' && src !== null) { 543 | const dst = copy(src, options); 544 | 545 | parents.push(src); 546 | nodes.push(dst); 547 | 548 | const iteratorFunction = options.includeSymbols ? own_enumerable_keys : Object.keys; 549 | for (const key of iteratorFunction(src)) { 550 | dst[key] = clone(src[key]); 551 | } 552 | 553 | parents.pop(); 554 | nodes.pop(); 555 | return dst; 556 | } 557 | 558 | return src; 559 | })(this.#value); 560 | } 561 | } 562 | 563 | const traverse = (obj: any, options?: TraverseOptions): Traverse => { 564 | return new Traverse(obj, options); 565 | }; 566 | 567 | /** 568 | * Get the element at the array `path`. 569 | */ 570 | traverse.get = (obj: any, paths: PropertyKey[], options?: TraverseOptions): any => { 571 | return new Traverse(obj, options).get(paths); 572 | }; 573 | 574 | /** 575 | * Set the element at the array `path` to `value`. 576 | */ 577 | traverse.set = (obj: any, path: PropertyKey[], value: any, options?: TraverseOptions): any => { 578 | return new Traverse(obj, options).set(path, value); 579 | }; 580 | 581 | /** 582 | * Return whether the element at the array `path` exists. 583 | */ 584 | traverse.has = (obj: any, paths: PropertyKey[], options?: TraverseOptions): boolean => { 585 | return new Traverse(obj, options).has(paths); 586 | }; 587 | 588 | /** 589 | * Execute `fn` for each node in the object and return a new object with the results of the walk. To update nodes in the result use `this.update(value)`. 590 | */ 591 | traverse.map = ( 592 | obj: any, 593 | cb: (this: TraverseContext, v: any) => void, 594 | options?: TraverseOptions, 595 | ): any => { 596 | return new Traverse(obj, options).map(cb); 597 | }; 598 | 599 | /** 600 | * Execute `fn` for each node in the object but unlike `.map()`, when `this.update()` is called it updates the object in-place. 601 | */ 602 | traverse.forEach = ( 603 | obj: any, 604 | cb: (this: TraverseContext, v: any) => void, 605 | options?: TraverseOptions, 606 | ): any => { 607 | return new Traverse(obj, options).forEach(cb); 608 | }; 609 | 610 | /** 611 | * For each node in the object, perform a [left-fold](http://en.wikipedia.org/wiki/Fold_(higher-order_function)) with the return value of `fn(acc, node)`. 612 | * 613 | * If `init` isn't specified, `init` is set to the root object for the first step and the root element is skipped. 614 | */ 615 | traverse.reduce = ( 616 | obj: any, 617 | cb: (this: TraverseContext, acc: any, v: any) => void, 618 | init?: any, 619 | options?: TraverseOptions, 620 | ): any => { 621 | return new Traverse(obj, options).reduce(cb, init); 622 | }; 623 | 624 | /** 625 | * Return an `Array` of every possible non-cyclic path in the object. 626 | * Paths are `Array`s of string keys. 627 | */ 628 | traverse.paths = (obj: any, options?: TraverseOptions): PropertyKey[][] => { 629 | return new Traverse(obj, options).paths(); 630 | }; 631 | 632 | /** 633 | * Return an `Array` of every node in the object. 634 | */ 635 | traverse.nodes = (obj: any, options?: TraverseOptions): any[] => { 636 | return new Traverse(obj, options).nodes(); 637 | }; 638 | 639 | /** 640 | * Create a deep clone of the object. 641 | */ 642 | traverse.clone = (obj: any, options?: TraverseOptions): any => { 643 | return new Traverse(obj, options).clone(); 644 | }; 645 | 646 | export default traverse; 647 | -------------------------------------------------------------------------------- /pnpm-lock.yaml: -------------------------------------------------------------------------------- 1 | lockfileVersion: '9.0' 2 | 3 | settings: 4 | autoInstallPeers: true 5 | excludeLinksFromLockfile: false 6 | 7 | importers: 8 | 9 | .: 10 | devDependencies: 11 | '@changesets/cli': 12 | specifier: ^2.27.7 13 | version: 2.27.7 14 | '@swc/core': 15 | specifier: ^1.6.13 16 | version: 1.6.13 17 | '@types/node': 18 | specifier: ^20.14.10 19 | version: 20.14.10 20 | '@vitest/coverage-v8': 21 | specifier: ^2.0.5 22 | version: 2.0.5(vitest@2.0.5(@types/node@20.14.10)(terser@5.31.2)) 23 | terser: 24 | specifier: ^5.31.2 25 | version: 5.31.2 26 | tsup: 27 | specifier: ^8.1.0 28 | version: 8.1.0(@swc/core@1.6.13)(postcss@8.4.39)(typescript@5.5.3) 29 | typescript: 30 | specifier: ^5.5.3 31 | version: 5.5.3 32 | vitest: 33 | specifier: ^2.0.5 34 | version: 2.0.5(@types/node@20.14.10)(terser@5.31.2) 35 | 36 | packages: 37 | 38 | '@ampproject/remapping@2.3.0': 39 | resolution: {integrity: sha512-30iZtAPgz+LTIYoeivqYo853f02jBYSd5uGnGpkFV0M3xOt9aN73erkgYAmZU43x4VfqcnLxW9Kpg3R5LC4YYw==} 40 | engines: {node: '>=6.0.0'} 41 | 42 | '@babel/helper-string-parser@7.24.8': 43 | resolution: {integrity: sha512-pO9KhhRcuUyGnJWwyEgnRJTSIZHiT+vMD0kPeD+so0l7mxkMT19g3pjY9GTnHySck/hDzq+dtW/4VgnMkippsQ==} 44 | engines: {node: '>=6.9.0'} 45 | 46 | '@babel/helper-validator-identifier@7.24.7': 47 | resolution: {integrity: sha512-rR+PBcQ1SMQDDyF6X0wxtG8QyLCgUB0eRAGguqRLfkCA87l7yAP7ehq8SNj96OOGTO8OBV70KhuFYcIkHXOg0w==} 48 | engines: {node: '>=6.9.0'} 49 | 50 | '@babel/parser@7.25.3': 51 | resolution: {integrity: sha512-iLTJKDbJ4hMvFPgQwwsVoxtHyWpKKPBrxkANrSYewDPaPpT5py5yeVkgPIJ7XYXhndxJpaA3PyALSXQ7u8e/Dw==} 52 | engines: {node: '>=6.0.0'} 53 | hasBin: true 54 | 55 | '@babel/runtime@7.25.0': 56 | resolution: {integrity: sha512-7dRy4DwXwtzBrPbZflqxnvfxLF8kdZXPkhymtDeFoFqE6ldzjQFgYTtYIFARcLEYDrqfBfYcZt1WqFxRoyC9Rw==} 57 | engines: {node: '>=6.9.0'} 58 | 59 | '@babel/types@7.25.2': 60 | resolution: {integrity: sha512-YTnYtra7W9e6/oAZEHj0bJehPRUlLH9/fbpT5LfB0NhQXyALCRkRs3zH9v07IYhkgpqX6Z78FnuccZr/l4Fs4Q==} 61 | engines: {node: '>=6.9.0'} 62 | 63 | '@bcoe/v8-coverage@0.2.3': 64 | resolution: {integrity: sha512-0hYQ8SB4Db5zvZB4axdMHGwEaQjkZzFjQiN9LVYvIFB2nSUHW9tYpxWriPrWDASIxiaXax83REcLxuSdnGPZtw==} 65 | 66 | '@changesets/apply-release-plan@7.0.4': 67 | resolution: {integrity: sha512-HLFwhKWayKinWAul0Vj+76jVx1Pc2v55MGPVjZ924Y/ROeSsBMFutv9heHmCUj48lJyRfOTJG5+ar+29FUky/A==} 68 | 69 | '@changesets/assemble-release-plan@6.0.3': 70 | resolution: {integrity: sha512-bLNh9/Lgl1VwkjWZTq8JmRqH+hj7/Yzfz0jsQ/zJJ+FTmVqmqPj3szeKOri8O/hEM8JmHW019vh2gTO9iq5Cuw==} 71 | 72 | '@changesets/changelog-git@0.2.0': 73 | resolution: {integrity: sha512-bHOx97iFI4OClIT35Lok3sJAwM31VbUM++gnMBV16fdbtBhgYu4dxsphBF/0AZZsyAHMrnM0yFcj5gZM1py6uQ==} 74 | 75 | '@changesets/cli@2.27.7': 76 | resolution: {integrity: sha512-6lr8JltiiXPIjDeYg4iM2MeePP6VN/JkmqBsVA5XRiy01hGS3y629LtSDvKcycj/w/5Eur1rEwby/MjcYS+e2A==} 77 | hasBin: true 78 | 79 | '@changesets/config@3.0.2': 80 | resolution: {integrity: sha512-cdEhS4t8woKCX2M8AotcV2BOWnBp09sqICxKapgLHf9m5KdENpWjyrFNMjkLqGJtUys9U+w93OxWT0czorVDfw==} 81 | 82 | '@changesets/errors@0.2.0': 83 | resolution: {integrity: sha512-6BLOQUscTpZeGljvyQXlWOItQyU71kCdGz7Pi8H8zdw6BI0g3m43iL4xKUVPWtG+qrrL9DTjpdn8eYuCQSRpow==} 84 | 85 | '@changesets/get-dependents-graph@2.1.1': 86 | resolution: {integrity: sha512-LRFjjvigBSzfnPU2n/AhFsuWR5DK++1x47aq6qZ8dzYsPtS/I5mNhIGAS68IAxh1xjO9BTtz55FwefhANZ+FCA==} 87 | 88 | '@changesets/get-release-plan@4.0.3': 89 | resolution: {integrity: sha512-6PLgvOIwTSdJPTtpdcr3sLtGatT+Jr22+cQwEBJBy6wP0rjB4yJ9lv583J9fVpn1bfQlBkDa8JxbS2g/n9lIyA==} 90 | 91 | '@changesets/get-version-range-type@0.4.0': 92 | resolution: {integrity: sha512-hwawtob9DryoGTpixy1D3ZXbGgJu1Rhr+ySH2PvTLHvkZuQ7sRT4oQwMh0hbqZH1weAooedEjRsbrWcGLCeyVQ==} 93 | 94 | '@changesets/git@3.0.0': 95 | resolution: {integrity: sha512-vvhnZDHe2eiBNRFHEgMiGd2CT+164dfYyrJDhwwxTVD/OW0FUD6G7+4DIx1dNwkwjHyzisxGAU96q0sVNBns0w==} 96 | 97 | '@changesets/logger@0.1.0': 98 | resolution: {integrity: sha512-pBrJm4CQm9VqFVwWnSqKEfsS2ESnwqwH+xR7jETxIErZcfd1u2zBSqrHbRHR7xjhSgep9x2PSKFKY//FAshA3g==} 99 | 100 | '@changesets/parse@0.4.0': 101 | resolution: {integrity: sha512-TS/9KG2CdGXS27S+QxbZXgr8uPsP4yNJYb4BC2/NeFUj80Rni3TeD2qwWmabymxmrLo7JEsytXH1FbpKTbvivw==} 102 | 103 | '@changesets/pre@2.0.0': 104 | resolution: {integrity: sha512-HLTNYX/A4jZxc+Sq8D1AMBsv+1qD6rmmJtjsCJa/9MSRybdxh0mjbTvE6JYZQ/ZiQ0mMlDOlGPXTm9KLTU3jyw==} 105 | 106 | '@changesets/read@0.6.0': 107 | resolution: {integrity: sha512-ZypqX8+/im1Fm98K4YcZtmLKgjs1kDQ5zHpc2U1qdtNBmZZfo/IBiG162RoP0CUF05tvp2y4IspH11PLnPxuuw==} 108 | 109 | '@changesets/should-skip-package@0.1.0': 110 | resolution: {integrity: sha512-FxG6Mhjw7yFStlSM7Z0Gmg3RiyQ98d/9VpQAZ3Fzr59dCOM9G6ZdYbjiSAt0XtFr9JR5U2tBaJWPjrkGGc618g==} 111 | 112 | '@changesets/types@4.1.0': 113 | resolution: {integrity: sha512-LDQvVDv5Kb50ny2s25Fhm3d9QSZimsoUGBsUioj6MC3qbMUCuC8GPIvk/M6IvXx3lYhAs0lwWUQLb+VIEUCECw==} 114 | 115 | '@changesets/types@6.0.0': 116 | resolution: {integrity: sha512-b1UkfNulgKoWfqyHtzKS5fOZYSJO+77adgL7DLRDr+/7jhChN+QcHnbjiQVOz/U+Ts3PGNySq7diAItzDgugfQ==} 117 | 118 | '@changesets/write@0.3.1': 119 | resolution: {integrity: sha512-SyGtMXzH3qFqlHKcvFY2eX+6b0NGiFcNav8AFsYwy5l8hejOeoeTDemu5Yjmke2V5jpzY+pBvM0vCCQ3gdZpfw==} 120 | 121 | '@esbuild/aix-ppc64@0.21.5': 122 | resolution: {integrity: sha512-1SDgH6ZSPTlggy1yI6+Dbkiz8xzpHJEVAlF/AM1tHPLsf5STom9rwtjE4hKAF20FfXXNTFqEYXyJNWh1GiZedQ==} 123 | engines: {node: '>=12'} 124 | cpu: [ppc64] 125 | os: [aix] 126 | 127 | '@esbuild/android-arm64@0.21.5': 128 | resolution: {integrity: sha512-c0uX9VAUBQ7dTDCjq+wdyGLowMdtR/GoC2U5IYk/7D1H1JYC0qseD7+11iMP2mRLN9RcCMRcjC4YMclCzGwS/A==} 129 | engines: {node: '>=12'} 130 | cpu: [arm64] 131 | os: [android] 132 | 133 | '@esbuild/android-arm@0.21.5': 134 | resolution: {integrity: sha512-vCPvzSjpPHEi1siZdlvAlsPxXl7WbOVUBBAowWug4rJHb68Ox8KualB+1ocNvT5fjv6wpkX6o/iEpbDrf68zcg==} 135 | engines: {node: '>=12'} 136 | cpu: [arm] 137 | os: [android] 138 | 139 | '@esbuild/android-x64@0.21.5': 140 | resolution: {integrity: sha512-D7aPRUUNHRBwHxzxRvp856rjUHRFW1SdQATKXH2hqA0kAZb1hKmi02OpYRacl0TxIGz/ZmXWlbZgjwWYaCakTA==} 141 | engines: {node: '>=12'} 142 | cpu: [x64] 143 | os: [android] 144 | 145 | '@esbuild/darwin-arm64@0.21.5': 146 | resolution: {integrity: sha512-DwqXqZyuk5AiWWf3UfLiRDJ5EDd49zg6O9wclZ7kUMv2WRFr4HKjXp/5t8JZ11QbQfUS6/cRCKGwYhtNAY88kQ==} 147 | engines: {node: '>=12'} 148 | cpu: [arm64] 149 | os: [darwin] 150 | 151 | '@esbuild/darwin-x64@0.21.5': 152 | resolution: {integrity: sha512-se/JjF8NlmKVG4kNIuyWMV/22ZaerB+qaSi5MdrXtd6R08kvs2qCN4C09miupktDitvh8jRFflwGFBQcxZRjbw==} 153 | engines: {node: '>=12'} 154 | cpu: [x64] 155 | os: [darwin] 156 | 157 | '@esbuild/freebsd-arm64@0.21.5': 158 | resolution: {integrity: sha512-5JcRxxRDUJLX8JXp/wcBCy3pENnCgBR9bN6JsY4OmhfUtIHe3ZW0mawA7+RDAcMLrMIZaf03NlQiX9DGyB8h4g==} 159 | engines: {node: '>=12'} 160 | cpu: [arm64] 161 | os: [freebsd] 162 | 163 | '@esbuild/freebsd-x64@0.21.5': 164 | resolution: {integrity: sha512-J95kNBj1zkbMXtHVH29bBriQygMXqoVQOQYA+ISs0/2l3T9/kj42ow2mpqerRBxDJnmkUDCaQT/dfNXWX/ZZCQ==} 165 | engines: {node: '>=12'} 166 | cpu: [x64] 167 | os: [freebsd] 168 | 169 | '@esbuild/linux-arm64@0.21.5': 170 | resolution: {integrity: sha512-ibKvmyYzKsBeX8d8I7MH/TMfWDXBF3db4qM6sy+7re0YXya+K1cem3on9XgdT2EQGMu4hQyZhan7TeQ8XkGp4Q==} 171 | engines: {node: '>=12'} 172 | cpu: [arm64] 173 | os: [linux] 174 | 175 | '@esbuild/linux-arm@0.21.5': 176 | resolution: {integrity: sha512-bPb5AHZtbeNGjCKVZ9UGqGwo8EUu4cLq68E95A53KlxAPRmUyYv2D6F0uUI65XisGOL1hBP5mTronbgo+0bFcA==} 177 | engines: {node: '>=12'} 178 | cpu: [arm] 179 | os: [linux] 180 | 181 | '@esbuild/linux-ia32@0.21.5': 182 | resolution: {integrity: sha512-YvjXDqLRqPDl2dvRODYmmhz4rPeVKYvppfGYKSNGdyZkA01046pLWyRKKI3ax8fbJoK5QbxblURkwK/MWY18Tg==} 183 | engines: {node: '>=12'} 184 | cpu: [ia32] 185 | os: [linux] 186 | 187 | '@esbuild/linux-loong64@0.21.5': 188 | resolution: {integrity: sha512-uHf1BmMG8qEvzdrzAqg2SIG/02+4/DHB6a9Kbya0XDvwDEKCoC8ZRWI5JJvNdUjtciBGFQ5PuBlpEOXQj+JQSg==} 189 | engines: {node: '>=12'} 190 | cpu: [loong64] 191 | os: [linux] 192 | 193 | '@esbuild/linux-mips64el@0.21.5': 194 | resolution: {integrity: sha512-IajOmO+KJK23bj52dFSNCMsz1QP1DqM6cwLUv3W1QwyxkyIWecfafnI555fvSGqEKwjMXVLokcV5ygHW5b3Jbg==} 195 | engines: {node: '>=12'} 196 | cpu: [mips64el] 197 | os: [linux] 198 | 199 | '@esbuild/linux-ppc64@0.21.5': 200 | resolution: {integrity: sha512-1hHV/Z4OEfMwpLO8rp7CvlhBDnjsC3CttJXIhBi+5Aj5r+MBvy4egg7wCbe//hSsT+RvDAG7s81tAvpL2XAE4w==} 201 | engines: {node: '>=12'} 202 | cpu: [ppc64] 203 | os: [linux] 204 | 205 | '@esbuild/linux-riscv64@0.21.5': 206 | resolution: {integrity: sha512-2HdXDMd9GMgTGrPWnJzP2ALSokE/0O5HhTUvWIbD3YdjME8JwvSCnNGBnTThKGEB91OZhzrJ4qIIxk/SBmyDDA==} 207 | engines: {node: '>=12'} 208 | cpu: [riscv64] 209 | os: [linux] 210 | 211 | '@esbuild/linux-s390x@0.21.5': 212 | resolution: {integrity: sha512-zus5sxzqBJD3eXxwvjN1yQkRepANgxE9lgOW2qLnmr8ikMTphkjgXu1HR01K4FJg8h1kEEDAqDcZQtbrRnB41A==} 213 | engines: {node: '>=12'} 214 | cpu: [s390x] 215 | os: [linux] 216 | 217 | '@esbuild/linux-x64@0.21.5': 218 | resolution: {integrity: sha512-1rYdTpyv03iycF1+BhzrzQJCdOuAOtaqHTWJZCWvijKD2N5Xu0TtVC8/+1faWqcP9iBCWOmjmhoH94dH82BxPQ==} 219 | engines: {node: '>=12'} 220 | cpu: [x64] 221 | os: [linux] 222 | 223 | '@esbuild/netbsd-x64@0.21.5': 224 | resolution: {integrity: sha512-Woi2MXzXjMULccIwMnLciyZH4nCIMpWQAs049KEeMvOcNADVxo0UBIQPfSmxB3CWKedngg7sWZdLvLczpe0tLg==} 225 | engines: {node: '>=12'} 226 | cpu: [x64] 227 | os: [netbsd] 228 | 229 | '@esbuild/openbsd-x64@0.21.5': 230 | resolution: {integrity: sha512-HLNNw99xsvx12lFBUwoT8EVCsSvRNDVxNpjZ7bPn947b8gJPzeHWyNVhFsaerc0n3TsbOINvRP2byTZ5LKezow==} 231 | engines: {node: '>=12'} 232 | cpu: [x64] 233 | os: [openbsd] 234 | 235 | '@esbuild/sunos-x64@0.21.5': 236 | resolution: {integrity: sha512-6+gjmFpfy0BHU5Tpptkuh8+uw3mnrvgs+dSPQXQOv3ekbordwnzTVEb4qnIvQcYXq6gzkyTnoZ9dZG+D4garKg==} 237 | engines: {node: '>=12'} 238 | cpu: [x64] 239 | os: [sunos] 240 | 241 | '@esbuild/win32-arm64@0.21.5': 242 | resolution: {integrity: sha512-Z0gOTd75VvXqyq7nsl93zwahcTROgqvuAcYDUr+vOv8uHhNSKROyU961kgtCD1e95IqPKSQKH7tBTslnS3tA8A==} 243 | engines: {node: '>=12'} 244 | cpu: [arm64] 245 | os: [win32] 246 | 247 | '@esbuild/win32-ia32@0.21.5': 248 | resolution: {integrity: sha512-SWXFF1CL2RVNMaVs+BBClwtfZSvDgtL//G/smwAc5oVK/UPu2Gu9tIaRgFmYFFKrmg3SyAjSrElf0TiJ1v8fYA==} 249 | engines: {node: '>=12'} 250 | cpu: [ia32] 251 | os: [win32] 252 | 253 | '@esbuild/win32-x64@0.21.5': 254 | resolution: {integrity: sha512-tQd/1efJuzPC6rCFwEvLtci/xNFcTZknmXs98FYDfGE4wP9ClFV98nyKrzJKVPMhdDnjzLhdUyMX4PsQAPjwIw==} 255 | engines: {node: '>=12'} 256 | cpu: [x64] 257 | os: [win32] 258 | 259 | '@isaacs/cliui@8.0.2': 260 | resolution: {integrity: sha512-O8jcjabXaleOG9DQ0+ARXWZBTfnP4WNAqzuiJK7ll44AmxGKv/J2M4TPjxjY3znBCfvBXFzucm1twdyFybFqEA==} 261 | engines: {node: '>=12'} 262 | 263 | '@istanbuljs/schema@0.1.3': 264 | resolution: {integrity: sha512-ZXRY4jNvVgSVQ8DL3LTcakaAtXwTVUxE81hslsyD2AtoXW/wVob10HkOJ1X/pAlcI7D+2YoZKg5do8G/w6RYgA==} 265 | engines: {node: '>=8'} 266 | 267 | '@jridgewell/gen-mapping@0.3.5': 268 | resolution: {integrity: sha512-IzL8ZoEDIBRWEzlCcRhOaCupYyN5gdIK+Q6fbFdPDg6HqX6jpkItn7DFIpW9LQzXG6Df9sA7+OKnq0qlz/GaQg==} 269 | engines: {node: '>=6.0.0'} 270 | 271 | '@jridgewell/resolve-uri@3.1.2': 272 | resolution: {integrity: sha512-bRISgCIjP20/tbWSPWMEi54QVPRZExkuD9lJL+UIxUKtwVJA8wW1Trb1jMs1RFXo1CBTNZ/5hpC9QvmKWdopKw==} 273 | engines: {node: '>=6.0.0'} 274 | 275 | '@jridgewell/set-array@1.2.1': 276 | resolution: {integrity: sha512-R8gLRTZeyp03ymzP/6Lil/28tGeGEzhx1q2k703KGWRAI1VdvPIXdG70VJc2pAMw3NA6JKL5hhFu1sJX0Mnn/A==} 277 | engines: {node: '>=6.0.0'} 278 | 279 | '@jridgewell/source-map@0.3.6': 280 | resolution: {integrity: sha512-1ZJTZebgqllO79ue2bm3rIGud/bOe0pP5BjSRCRxxYkEZS8STV7zN84UBbiYu7jy+eCKSnVIUgoWWE/tt+shMQ==} 281 | 282 | '@jridgewell/sourcemap-codec@1.5.0': 283 | resolution: {integrity: sha512-gv3ZRaISU3fjPAgNsriBRqGWQL6quFx04YMPW/zD8XMLsU32mhCCbfbO6KZFLjvYpCZ8zyDEgqsgf+PwPaM7GQ==} 284 | 285 | '@jridgewell/trace-mapping@0.3.25': 286 | resolution: {integrity: sha512-vNk6aEwybGtawWmy/PzwnGDOjCkLWSD2wqvjGGAgOAwCGWySYXfYoxt00IJkTF+8Lb57DwOb3Aa0o9CApepiYQ==} 287 | 288 | '@manypkg/find-root@1.1.0': 289 | resolution: {integrity: sha512-mki5uBvhHzO8kYYix/WRy2WX8S3B5wdVSc9D6KcU5lQNglP2yt58/VfLuAK49glRXChosY8ap2oJ1qgma3GUVA==} 290 | 291 | '@manypkg/get-packages@1.1.3': 292 | resolution: {integrity: sha512-fo+QhuU3qE/2TQMQmbVMqaQ6EWbMhi4ABWP+O4AM1NqPBuy0OrApV5LO6BrrgnhtAHS2NH6RrVk9OL181tTi8A==} 293 | 294 | '@nodelib/fs.scandir@2.1.5': 295 | resolution: {integrity: sha512-vq24Bq3ym5HEQm2NKCr3yXDwjc7vTsEThRDnkp2DK9p1uqLR+DHurm/NOTo0KG7HYHU7eppKZj3MyqYuMBf62g==} 296 | engines: {node: '>= 8'} 297 | 298 | '@nodelib/fs.stat@2.0.5': 299 | resolution: {integrity: sha512-RkhPPp2zrqDAQA/2jNhnztcPAlv64XdhIp7a7454A5ovI7Bukxgt7MX7udwAu3zg1DcpPU0rz3VV1SeaqvY4+A==} 300 | engines: {node: '>= 8'} 301 | 302 | '@nodelib/fs.walk@1.2.8': 303 | resolution: {integrity: sha512-oGB+UxlgWcgQkgwo8GcEGwemoTFt3FIO9ababBmaGwXIoBKZ+GTy0pP185beGg7Llih/NSHSV2XAs1lnznocSg==} 304 | engines: {node: '>= 8'} 305 | 306 | '@pkgjs/parseargs@0.11.0': 307 | resolution: {integrity: sha512-+1VkjdD0QBLPodGrJUeqarH8VAIvQODIbwh9XpP5Syisf7YoQgsJKPNFoqqLQlu+VQ/tVSshMR6loPMn8U+dPg==} 308 | engines: {node: '>=14'} 309 | 310 | '@rollup/rollup-android-arm-eabi@4.18.1': 311 | resolution: {integrity: sha512-lncuC4aHicncmbORnx+dUaAgzee9cm/PbIqgWz1PpXuwc+sa1Ct83tnqUDy/GFKleLiN7ZIeytM6KJ4cAn1SxA==} 312 | cpu: [arm] 313 | os: [android] 314 | 315 | '@rollup/rollup-android-arm64@4.18.1': 316 | resolution: {integrity: sha512-F/tkdw0WSs4ojqz5Ovrw5r9odqzFjb5LIgHdHZG65dFI1lWTWRVy32KDJLKRISHgJvqUeUhdIvy43fX41znyDg==} 317 | cpu: [arm64] 318 | os: [android] 319 | 320 | '@rollup/rollup-darwin-arm64@4.18.1': 321 | resolution: {integrity: sha512-vk+ma8iC1ebje/ahpxpnrfVQJibTMyHdWpOGZ3JpQ7Mgn/3QNHmPq7YwjZbIE7km73dH5M1e6MRRsnEBW7v5CQ==} 322 | cpu: [arm64] 323 | os: [darwin] 324 | 325 | '@rollup/rollup-darwin-x64@4.18.1': 326 | resolution: {integrity: sha512-IgpzXKauRe1Tafcej9STjSSuG0Ghu/xGYH+qG6JwsAUxXrnkvNHcq/NL6nz1+jzvWAnQkuAJ4uIwGB48K9OCGA==} 327 | cpu: [x64] 328 | os: [darwin] 329 | 330 | '@rollup/rollup-linux-arm-gnueabihf@4.18.1': 331 | resolution: {integrity: sha512-P9bSiAUnSSM7EmyRK+e5wgpqai86QOSv8BwvkGjLwYuOpaeomiZWifEos517CwbG+aZl1T4clSE1YqqH2JRs+g==} 332 | cpu: [arm] 333 | os: [linux] 334 | 335 | '@rollup/rollup-linux-arm-musleabihf@4.18.1': 336 | resolution: {integrity: sha512-5RnjpACoxtS+aWOI1dURKno11d7krfpGDEn19jI8BuWmSBbUC4ytIADfROM1FZrFhQPSoP+KEa3NlEScznBTyQ==} 337 | cpu: [arm] 338 | os: [linux] 339 | 340 | '@rollup/rollup-linux-arm64-gnu@4.18.1': 341 | resolution: {integrity: sha512-8mwmGD668m8WaGbthrEYZ9CBmPug2QPGWxhJxh/vCgBjro5o96gL04WLlg5BA233OCWLqERy4YUzX3bJGXaJgQ==} 342 | cpu: [arm64] 343 | os: [linux] 344 | 345 | '@rollup/rollup-linux-arm64-musl@4.18.1': 346 | resolution: {integrity: sha512-dJX9u4r4bqInMGOAQoGYdwDP8lQiisWb9et+T84l2WXk41yEej8v2iGKodmdKimT8cTAYt0jFb+UEBxnPkbXEQ==} 347 | cpu: [arm64] 348 | os: [linux] 349 | 350 | '@rollup/rollup-linux-powerpc64le-gnu@4.18.1': 351 | resolution: {integrity: sha512-V72cXdTl4EI0x6FNmho4D502sy7ed+LuVW6Ym8aI6DRQ9hQZdp5sj0a2usYOlqvFBNKQnLQGwmYnujo2HvjCxQ==} 352 | cpu: [ppc64] 353 | os: [linux] 354 | 355 | '@rollup/rollup-linux-riscv64-gnu@4.18.1': 356 | resolution: {integrity: sha512-f+pJih7sxoKmbjghrM2RkWo2WHUW8UbfxIQiWo5yeCaCM0TveMEuAzKJte4QskBp1TIinpnRcxkquY+4WuY/tg==} 357 | cpu: [riscv64] 358 | os: [linux] 359 | 360 | '@rollup/rollup-linux-s390x-gnu@4.18.1': 361 | resolution: {integrity: sha512-qb1hMMT3Fr/Qz1OKovCuUM11MUNLUuHeBC2DPPAWUYYUAOFWaxInaTwTQmc7Fl5La7DShTEpmYwgdt2hG+4TEg==} 362 | cpu: [s390x] 363 | os: [linux] 364 | 365 | '@rollup/rollup-linux-x64-gnu@4.18.1': 366 | resolution: {integrity: sha512-7O5u/p6oKUFYjRbZkL2FLbwsyoJAjyeXHCU3O4ndvzg2OFO2GinFPSJFGbiwFDaCFc+k7gs9CF243PwdPQFh5g==} 367 | cpu: [x64] 368 | os: [linux] 369 | 370 | '@rollup/rollup-linux-x64-musl@4.18.1': 371 | resolution: {integrity: sha512-pDLkYITdYrH/9Cv/Vlj8HppDuLMDUBmgsM0+N+xLtFd18aXgM9Nyqupb/Uw+HeidhfYg2lD6CXvz6CjoVOaKjQ==} 372 | cpu: [x64] 373 | os: [linux] 374 | 375 | '@rollup/rollup-win32-arm64-msvc@4.18.1': 376 | resolution: {integrity: sha512-W2ZNI323O/8pJdBGil1oCauuCzmVd9lDmWBBqxYZcOqWD6aWqJtVBQ1dFrF4dYpZPks6F+xCZHfzG5hYlSHZ6g==} 377 | cpu: [arm64] 378 | os: [win32] 379 | 380 | '@rollup/rollup-win32-ia32-msvc@4.18.1': 381 | resolution: {integrity: sha512-ELfEX1/+eGZYMaCIbK4jqLxO1gyTSOIlZr6pbC4SRYFaSIDVKOnZNMdoZ+ON0mrFDp4+H5MhwNC1H/AhE3zQLg==} 382 | cpu: [ia32] 383 | os: [win32] 384 | 385 | '@rollup/rollup-win32-x64-msvc@4.18.1': 386 | resolution: {integrity: sha512-yjk2MAkQmoaPYCSu35RLJ62+dz358nE83VfTePJRp8CG7aMg25mEJYpXFiD+NcevhX8LxD5OP5tktPXnXN7GDw==} 387 | cpu: [x64] 388 | os: [win32] 389 | 390 | '@swc/core-darwin-arm64@1.6.13': 391 | resolution: {integrity: sha512-SOF4buAis72K22BGJ3N8y88mLNfxLNprTuJUpzikyMGrvkuBFNcxYtMhmomO0XHsgLDzOJ+hWzcgjRNzjMsUcQ==} 392 | engines: {node: '>=10'} 393 | cpu: [arm64] 394 | os: [darwin] 395 | 396 | '@swc/core-darwin-x64@1.6.13': 397 | resolution: {integrity: sha512-AW8akFSC+tmPE6YQQvK9S2A1B8pjnXEINg+gGgw0KRUUXunvu1/OEOeC5L2Co1wAwhD7bhnaefi06Qi9AiwOag==} 398 | engines: {node: '>=10'} 399 | cpu: [x64] 400 | os: [darwin] 401 | 402 | '@swc/core-linux-arm-gnueabihf@1.6.13': 403 | resolution: {integrity: sha512-f4gxxvDXVUm2HLYXRd311mSrmbpQF2MZ4Ja6XCQz1hWAxXdhRl1gpnZ+LH/xIfGSwQChrtLLVrkxdYUCVuIjFg==} 404 | engines: {node: '>=10'} 405 | cpu: [arm] 406 | os: [linux] 407 | 408 | '@swc/core-linux-arm64-gnu@1.6.13': 409 | resolution: {integrity: sha512-Nf/eoW2CbG8s+9JoLtjl9FByBXyQ5cjdBsA4efO7Zw4p+YSuXDgc8HRPC+E2+ns0praDpKNZtLvDtmF2lL+2Gg==} 410 | engines: {node: '>=10'} 411 | cpu: [arm64] 412 | os: [linux] 413 | 414 | '@swc/core-linux-arm64-musl@1.6.13': 415 | resolution: {integrity: sha512-2OysYSYtdw79prJYuKIiux/Gj0iaGEbpS2QZWCIY4X9sGoETJ5iMg+lY+YCrIxdkkNYd7OhIbXdYFyGs/w5LDg==} 416 | engines: {node: '>=10'} 417 | cpu: [arm64] 418 | os: [linux] 419 | 420 | '@swc/core-linux-x64-gnu@1.6.13': 421 | resolution: {integrity: sha512-PkR4CZYJNk5hcd2+tMWBpnisnmYsUzazI1O5X7VkIGFcGePTqJ/bWlfUIVVExWxvAI33PQFzLbzmN5scyIUyGQ==} 422 | engines: {node: '>=10'} 423 | cpu: [x64] 424 | os: [linux] 425 | 426 | '@swc/core-linux-x64-musl@1.6.13': 427 | resolution: {integrity: sha512-OdsY7wryTxCKwGQcwW9jwWg3cxaHBkTTHi91+5nm7hFPpmZMz1HivJrWAMwVE7iXFw+M4l6ugB/wCvpYrUAAjA==} 428 | engines: {node: '>=10'} 429 | cpu: [x64] 430 | os: [linux] 431 | 432 | '@swc/core-win32-arm64-msvc@1.6.13': 433 | resolution: {integrity: sha512-ap6uNmYjwk9M/+bFEuWRNl3hq4VqgQ/Lk+ID/F5WGqczNr0L7vEf+pOsRAn0F6EV+o/nyb3ePt8rLhE/wjHpPg==} 434 | engines: {node: '>=10'} 435 | cpu: [arm64] 436 | os: [win32] 437 | 438 | '@swc/core-win32-ia32-msvc@1.6.13': 439 | resolution: {integrity: sha512-IJ8KH4yIUHTnS/U1jwQmtbfQals7zWPG0a9hbEfIr4zI0yKzjd83lmtS09lm2Q24QBWOCFGEEbuZxR4tIlvfzA==} 440 | engines: {node: '>=10'} 441 | cpu: [ia32] 442 | os: [win32] 443 | 444 | '@swc/core-win32-x64-msvc@1.6.13': 445 | resolution: {integrity: sha512-f6/sx6LMuEnbuxtiSL/EkR0Y6qUHFw1XVrh6rwzKXptTipUdOY+nXpKoh+1UsBm/r7H0/5DtOdrn3q5ZHbFZjQ==} 446 | engines: {node: '>=10'} 447 | cpu: [x64] 448 | os: [win32] 449 | 450 | '@swc/core@1.6.13': 451 | resolution: {integrity: sha512-eailUYex6fkfaQTev4Oa3mwn0/e3mQU4H8y1WPuImYQESOQDtVrowwUGDSc19evpBbHpKtwM+hw8nLlhIsF+Tw==} 452 | engines: {node: '>=10'} 453 | peerDependencies: 454 | '@swc/helpers': '*' 455 | peerDependenciesMeta: 456 | '@swc/helpers': 457 | optional: true 458 | 459 | '@swc/counter@0.1.3': 460 | resolution: {integrity: sha512-e2BR4lsJkkRlKZ/qCHPw9ZaSxc0MVUd7gtbtaB7aMvHeJVYe8sOB8DBZkP2DtISHGSku9sCK6T6cnY0CtXrOCQ==} 461 | 462 | '@swc/types@0.1.9': 463 | resolution: {integrity: sha512-qKnCno++jzcJ4lM4NTfYifm1EFSCeIfKiAHAfkENZAV5Kl9PjJIyd2yeeVv6c/2CckuLyv2NmRC5pv6pm2WQBg==} 464 | 465 | '@types/estree@1.0.5': 466 | resolution: {integrity: sha512-/kYRxGDLWzHOB7q+wtSUQlFrtcdUccpfy+X+9iMBpHK8QLLhx2wIPYuS5DYtR9Wa/YlZAbIovy7qVdB1Aq6Lyw==} 467 | 468 | '@types/node@12.20.55': 469 | resolution: {integrity: sha512-J8xLz7q2OFulZ2cyGTLE1TbbZcjpno7FaN6zdJNrgAdrJ+DZzh/uFR6YrTb4C+nXakvud8Q4+rbhoIWlYQbUFQ==} 470 | 471 | '@types/node@20.14.10': 472 | resolution: {integrity: sha512-MdiXf+nDuMvY0gJKxyfZ7/6UFsETO7mGKF54MVD/ekJS6HdFtpZFBgrh6Pseu64XTb2MLyFPlbW6hj8HYRQNOQ==} 473 | 474 | '@types/semver@7.5.8': 475 | resolution: {integrity: sha512-I8EUhyrgfLrcTkzV3TSsGyl1tSuPrEDzr0yd5m90UgNxQkyDXULk3b6MlQqTCpZpNtWe1K0hzclnZkTcLBe2UQ==} 476 | 477 | '@vitest/coverage-v8@2.0.5': 478 | resolution: {integrity: sha512-qeFcySCg5FLO2bHHSa0tAZAOnAUbp4L6/A5JDuj9+bt53JREl8hpLjLHEWF0e/gWc8INVpJaqA7+Ene2rclpZg==} 479 | peerDependencies: 480 | vitest: 2.0.5 481 | 482 | '@vitest/expect@2.0.5': 483 | resolution: {integrity: sha512-yHZtwuP7JZivj65Gxoi8upUN2OzHTi3zVfjwdpu2WrvCZPLwsJ2Ey5ILIPccoW23dd/zQBlJ4/dhi7DWNyXCpA==} 484 | 485 | '@vitest/pretty-format@2.0.5': 486 | resolution: {integrity: sha512-h8k+1oWHfwTkyTkb9egzwNMfJAEx4veaPSnMeKbVSjp4euqGSbQlm5+6VHwTr7u4FJslVVsUG5nopCaAYdOmSQ==} 487 | 488 | '@vitest/runner@2.0.5': 489 | resolution: {integrity: sha512-TfRfZa6Bkk9ky4tW0z20WKXFEwwvWhRY+84CnSEtq4+3ZvDlJyY32oNTJtM7AW9ihW90tX/1Q78cb6FjoAs+ig==} 490 | 491 | '@vitest/snapshot@2.0.5': 492 | resolution: {integrity: sha512-SgCPUeDFLaM0mIUHfaArq8fD2WbaXG/zVXjRupthYfYGzc8ztbFbu6dUNOblBG7XLMR1kEhS/DNnfCZ2IhdDew==} 493 | 494 | '@vitest/spy@2.0.5': 495 | resolution: {integrity: sha512-c/jdthAhvJdpfVuaexSrnawxZz6pywlTPe84LUB2m/4t3rl2fTo9NFGBG4oWgaD+FTgDDV8hJ/nibT7IfH3JfA==} 496 | 497 | '@vitest/utils@2.0.5': 498 | resolution: {integrity: sha512-d8HKbqIcya+GR67mkZbrzhS5kKhtp8dQLcmRZLGTscGVg7yImT82cIrhtn2L8+VujWcy6KZweApgNmPsTAO/UQ==} 499 | 500 | acorn@8.12.1: 501 | resolution: {integrity: sha512-tcpGyI9zbizT9JbV6oYE477V6mTlXvvi0T0G3SNIYE2apm/G5huBa1+K89VGeovbg+jycCrfhl3ADxErOuO6Jg==} 502 | engines: {node: '>=0.4.0'} 503 | hasBin: true 504 | 505 | ansi-colors@4.1.3: 506 | resolution: {integrity: sha512-/6w/C21Pm1A7aZitlI5Ni/2J6FFQN8i1Cvz3kHABAAbw93v/NlvKdVOqz7CCWz/3iv/JplRSEEZ83XION15ovw==} 507 | engines: {node: '>=6'} 508 | 509 | ansi-regex@5.0.1: 510 | resolution: {integrity: sha512-quJQXlTSUGL2LH9SUXo8VwsY4soanhgo6LNSm84E1LBcE8s3O0wpdiRzyR9z/ZZJMlMWv37qOOb9pdJlMUEKFQ==} 511 | engines: {node: '>=8'} 512 | 513 | ansi-regex@6.0.1: 514 | resolution: {integrity: sha512-n5M855fKb2SsfMIiFFoVrABHJC8QtHwVx+mHWP3QcEqBHYienj5dHSgjbxtC0WEZXYt4wcD6zrQElDPhFuZgfA==} 515 | engines: {node: '>=12'} 516 | 517 | ansi-styles@3.2.1: 518 | resolution: {integrity: sha512-VT0ZI6kZRdTh8YyJw3SMbYm/u+NqfsAxEpWO0Pf9sq8/e94WxxOpPKx9FR1FlyCtOVDNOQ+8ntlqFxiRc+r5qA==} 519 | engines: {node: '>=4'} 520 | 521 | ansi-styles@4.3.0: 522 | resolution: {integrity: sha512-zbB9rCJAT1rbjiVDb2hqKFHNYLxgtk8NURxZ3IZwD3F6NtxbXZQCnnSi1Lkx+IDohdPlFp222wVALIheZJQSEg==} 523 | engines: {node: '>=8'} 524 | 525 | ansi-styles@6.2.1: 526 | resolution: {integrity: sha512-bN798gFfQX+viw3R7yrGWRqnrN2oRkEkUjjl4JNn4E8GxxbjtG3FbrEIIY3l8/hrwUwIeCZvi4QuOTP4MErVug==} 527 | engines: {node: '>=12'} 528 | 529 | any-promise@1.3.0: 530 | resolution: {integrity: sha512-7UvmKalWRt1wgjL1RrGxoSJW/0QZFIegpeGvZG9kjp8vrRu55XTHbwnqq2GpXm9uLbcuhxm3IqX9OB4MZR1b2A==} 531 | 532 | anymatch@3.1.3: 533 | resolution: {integrity: sha512-KMReFUr0B4t+D+OBkjR3KYqvocp2XaSzO55UcB6mgQMd3KbcE+mWTyvVV7D/zsdEbNnV6acZUutkiHQXvTr1Rw==} 534 | engines: {node: '>= 8'} 535 | 536 | argparse@1.0.10: 537 | resolution: {integrity: sha512-o5Roy6tNG4SL/FOkCAN6RzjiakZS25RLYFrcMttJqbdd8BWrnA+fGz57iN5Pb06pvBGvl5gQ0B48dJlslXvoTg==} 538 | 539 | array-union@2.1.0: 540 | resolution: {integrity: sha512-HGyxoOTYUyCM6stUe6EJgnd4EoewAI7zMdfqO+kGjnlZmBDz/cR5pf8r/cR4Wq60sL/p0IkcjUEEPwS3GFrIyw==} 541 | engines: {node: '>=8'} 542 | 543 | assertion-error@2.0.1: 544 | resolution: {integrity: sha512-Izi8RQcffqCeNVgFigKli1ssklIbpHnCYc6AknXGYoB6grJqyeby7jv12JUQgmTAnIDnbck1uxksT4dzN3PWBA==} 545 | engines: {node: '>=12'} 546 | 547 | balanced-match@1.0.2: 548 | resolution: {integrity: sha512-3oSeUO0TMV67hN1AmbXsK4yaqU7tjiHlbxRDZOpH0KW9+CeX4bRAaX0Anxt0tx2MrpRpWwQaPwIlISEJhYU5Pw==} 549 | 550 | better-path-resolve@1.0.0: 551 | resolution: {integrity: sha512-pbnl5XzGBdrFU/wT4jqmJVPn2B6UHPBOhzMQkY/SPUPB6QtUXtmBHBIwCbXJol93mOpGMnQyP/+BB19q04xj7g==} 552 | engines: {node: '>=4'} 553 | 554 | binary-extensions@2.3.0: 555 | resolution: {integrity: sha512-Ceh+7ox5qe7LJuLHoY0feh3pHuUDHAcRUeyL2VYghZwfpkNIy/+8Ocg0a3UuSoYzavmylwuLWQOf3hl0jjMMIw==} 556 | engines: {node: '>=8'} 557 | 558 | brace-expansion@2.0.1: 559 | resolution: {integrity: sha512-XnAIvQ8eM+kC6aULx6wuQiwVsnzsi9d3WxzV3FpWTGA19F621kwdbsAcFKXgKUHZWsy+mY6iL1sHTxWEFCytDA==} 560 | 561 | braces@3.0.3: 562 | resolution: {integrity: sha512-yQbXgO/OSZVD2IsiLlro+7Hf6Q18EJrKSEsdoMzKePKXct3gvD8oLcOQdIzGupr5Fj+EDe8gO/lxc1BzfMpxvA==} 563 | engines: {node: '>=8'} 564 | 565 | buffer-from@1.1.2: 566 | resolution: {integrity: sha512-E+XQCRwSbaaiChtv6k6Dwgc+bx+Bs6vuKJHHl5kox/BaKbhiXzqQOwK4cO22yElGp2OCmjwVhT3HmxgyPGnJfQ==} 567 | 568 | bundle-require@4.2.1: 569 | resolution: {integrity: sha512-7Q/6vkyYAwOmQNRw75x+4yRtZCZJXUDmHHlFdkiV0wgv/reNjtJwpu1jPJ0w2kbEpIM0uoKI3S4/f39dU7AjSA==} 570 | engines: {node: ^12.20.0 || ^14.13.1 || >=16.0.0} 571 | peerDependencies: 572 | esbuild: '>=0.17' 573 | 574 | cac@6.7.14: 575 | resolution: {integrity: sha512-b6Ilus+c3RrdDk+JhLKUAQfzzgLEPy6wcXqS7f/xe1EETvsDP6GORG7SFuOs6cID5YkqchW/LXZbX5bc8j7ZcQ==} 576 | engines: {node: '>=8'} 577 | 578 | chai@5.1.1: 579 | resolution: {integrity: sha512-pT1ZgP8rPNqUgieVaEY+ryQr6Q4HXNg8Ei9UnLUrjN4IA7dvQC5JB+/kxVcPNDHyBcc/26CXPkbNzq3qwrOEKA==} 580 | engines: {node: '>=12'} 581 | 582 | chalk@2.4.2: 583 | resolution: {integrity: sha512-Mti+f9lpJNcwF4tWV8/OrTTtF1gZi+f8FqlyAdouralcFWFQWF2+NgCHShjkCb+IFBLq9buZwE1xckQU4peSuQ==} 584 | engines: {node: '>=4'} 585 | 586 | chardet@0.7.0: 587 | resolution: {integrity: sha512-mT8iDcrh03qDGRRmoA2hmBJnxpllMR+0/0qlzjqZES6NdiWDcZkCNAk4rPFZ9Q85r27unkiNNg8ZOiwZXBHwcA==} 588 | 589 | check-error@2.1.1: 590 | resolution: {integrity: sha512-OAlb+T7V4Op9OwdkjmguYRqncdlx5JiofwOAUkmTF+jNdHwzTaTs4sRAGpzLF3oOz5xAyDGrPgeIDFQmDOTiJw==} 591 | engines: {node: '>= 16'} 592 | 593 | chokidar@3.6.0: 594 | resolution: {integrity: sha512-7VT13fmjotKpGipCW9JEQAusEPE+Ei8nl6/g4FBAmIm0GOOLMua9NDDo/DWp0ZAxCr3cPq5ZpBqmPAQgDda2Pw==} 595 | engines: {node: '>= 8.10.0'} 596 | 597 | ci-info@3.9.0: 598 | resolution: {integrity: sha512-NIxF55hv4nSqQswkAeiOi1r83xy8JldOFDTWiug55KBu9Jnblncd2U6ViHmYgHf01TPZS77NJBhBMKdWj9HQMQ==} 599 | engines: {node: '>=8'} 600 | 601 | color-convert@1.9.3: 602 | resolution: {integrity: sha512-QfAUtd+vFdAtFQcC8CCyYt1fYWxSqAiK2cSD6zDB8N3cpsEBAvRxp9zOGg6G/SHHJYAT88/az/IuDGALsNVbGg==} 603 | 604 | color-convert@2.0.1: 605 | resolution: {integrity: sha512-RRECPsj7iu/xb5oKYcsFHSppFNnsj/52OVTRKb4zP5onXwVF3zVmmToNcOfGC+CRDpfK/U584fMg38ZHCaElKQ==} 606 | engines: {node: '>=7.0.0'} 607 | 608 | color-name@1.1.3: 609 | resolution: {integrity: sha512-72fSenhMw2HZMTVHeCA9KCmpEIbzWiQsjN+BHcBbS9vr1mtt+vJjPdksIBNUmKAW8TFUDPJK5SUU3QhE9NEXDw==} 610 | 611 | color-name@1.1.4: 612 | resolution: {integrity: sha512-dOy+3AuW3a2wNbZHIuMZpTcgjGuLU/uBL/ubcZF9OXbDo8ff4O8yVp5Bf0efS8uEoYo5q4Fx7dY9OgQGXgAsQA==} 613 | 614 | commander@2.20.3: 615 | resolution: {integrity: sha512-GpVkmM8vF2vQUkj2LvZmD35JxeJOLCwJ9cUkugyk2nuhbv3+mJvpLYYt+0+USMxE+oj+ey/lJEnhZw75x/OMcQ==} 616 | 617 | commander@4.1.1: 618 | resolution: {integrity: sha512-NOKm8xhkzAjzFx8B2v5OAHT+u5pRQc2UCa2Vq9jYL/31o2wi9mxBA7LIFs3sV5VSC49z6pEhfbMULvShKj26WA==} 619 | engines: {node: '>= 6'} 620 | 621 | cross-spawn@5.1.0: 622 | resolution: {integrity: sha512-pTgQJ5KC0d2hcY8eyL1IzlBPYjTkyH72XRZPnLyKus2mBfNjQs3klqbJU2VILqZryAZUt9JOb3h/mWMy23/f5A==} 623 | 624 | cross-spawn@7.0.3: 625 | resolution: {integrity: sha512-iRDPJKUPVEND7dHPO8rkbOnPpyDygcDFtWjpeWNCgy8WP2rXcxXL8TskReQl6OrB2G7+UJrags1q15Fudc7G6w==} 626 | engines: {node: '>= 8'} 627 | 628 | debug@4.3.5: 629 | resolution: {integrity: sha512-pt0bNEmneDIvdL1Xsd9oDQ/wrQRkXDT4AUWlNZNPKvW5x/jyO9VFXkJUP07vQ2upmw5PlaITaPKc31jK13V+jg==} 630 | engines: {node: '>=6.0'} 631 | peerDependencies: 632 | supports-color: '*' 633 | peerDependenciesMeta: 634 | supports-color: 635 | optional: true 636 | 637 | deep-eql@5.0.2: 638 | resolution: {integrity: sha512-h5k/5U50IJJFpzfL6nO9jaaumfjO/f2NjK/oYB2Djzm4p9L+3T9qWpZqZ2hAbLPuuYq9wrU08WQyBTL5GbPk5Q==} 639 | engines: {node: '>=6'} 640 | 641 | detect-indent@6.1.0: 642 | resolution: {integrity: sha512-reYkTUJAZb9gUuZ2RvVCNhVHdg62RHnJ7WJl8ftMi4diZ6NWlciOzQN88pUhSELEwflJht4oQDv0F0BMlwaYtA==} 643 | engines: {node: '>=8'} 644 | 645 | dir-glob@3.0.1: 646 | resolution: {integrity: sha512-WkrWp9GR4KXfKGYzOLmTuGVi1UWFfws377n9cc55/tb6DuqyF6pcQ5AbiHEshaDpY9v6oaSr2XCDidGmMwdzIA==} 647 | engines: {node: '>=8'} 648 | 649 | eastasianwidth@0.2.0: 650 | resolution: {integrity: sha512-I88TYZWc9XiYHRQ4/3c5rjjfgkjhLyW2luGIheGERbNQ6OY7yTybanSpDXZa8y7VUP9YmDcYa+eyq4ca7iLqWA==} 651 | 652 | emoji-regex@8.0.0: 653 | resolution: {integrity: sha512-MSjYzcWNOA0ewAHpz0MxpYFvwg6yjy1NG3xteoqz644VCo/RPgnr1/GGt+ic3iJTzQ8Eu3TdM14SawnVUmGE6A==} 654 | 655 | emoji-regex@9.2.2: 656 | resolution: {integrity: sha512-L18DaJsXSUk2+42pv8mLs5jJT2hqFkFE4j21wOmgbUqsZ2hL72NsUU785g9RXgo3s0ZNgVl42TiHp3ZtOv/Vyg==} 657 | 658 | enquirer@2.4.1: 659 | resolution: {integrity: sha512-rRqJg/6gd538VHvR3PSrdRBb/1Vy2YfzHqzvbhGIQpDRKIa4FgV/54b5Q1xYSxOOwKvjXweS26E0Q+nAMwp2pQ==} 660 | engines: {node: '>=8.6'} 661 | 662 | esbuild@0.21.5: 663 | resolution: {integrity: sha512-mg3OPMV4hXywwpoDxu3Qda5xCKQi+vCTZq8S9J/EpkhB2HzKXq4SNFZE3+NK93JYxc8VMSep+lOUSC/RVKaBqw==} 664 | engines: {node: '>=12'} 665 | hasBin: true 666 | 667 | escape-string-regexp@1.0.5: 668 | resolution: {integrity: sha512-vbRorB5FUQWvla16U8R/qgaFIya2qGzwDrNmCZuYKrbdSUMG6I1ZCGQRefkRVhuOkIGVne7BQ35DSfo1qvJqFg==} 669 | engines: {node: '>=0.8.0'} 670 | 671 | esprima@4.0.1: 672 | resolution: {integrity: sha512-eGuFFw7Upda+g4p+QHvnW0RyTX/SVeJBDM/gCtMARO0cLuT2HcEKnTPvhjV6aGeqrCB/sbNop0Kszm0jsaWU4A==} 673 | engines: {node: '>=4'} 674 | hasBin: true 675 | 676 | estree-walker@3.0.3: 677 | resolution: {integrity: sha512-7RUKfXgSMMkzt6ZuXmqapOurLGPPfgj6l9uRZ7lRGolvk0y2yocc35LdcxKC5PQZdn2DMqioAQ2NoWcrTKmm6g==} 678 | 679 | execa@5.1.1: 680 | resolution: {integrity: sha512-8uSpZZocAZRBAPIEINJj3Lo9HyGitllczc27Eh5YYojjMFMn8yHMDMaUHE2Jqfq05D/wucwI4JGURyXt1vchyg==} 681 | engines: {node: '>=10'} 682 | 683 | execa@8.0.1: 684 | resolution: {integrity: sha512-VyhnebXciFV2DESc+p6B+y0LjSm0krU4OgJN44qFAhBY0TJ+1V61tYD2+wHusZ6F9n5K+vl8k0sTy7PEfV4qpg==} 685 | engines: {node: '>=16.17'} 686 | 687 | extendable-error@0.1.7: 688 | resolution: {integrity: sha512-UOiS2in6/Q0FK0R0q6UY9vYpQ21mr/Qn1KOnte7vsACuNJf514WvCCUHSRCPcgjPT2bAhNIJdlE6bVap1GKmeg==} 689 | 690 | external-editor@3.1.0: 691 | resolution: {integrity: sha512-hMQ4CX1p1izmuLYyZqLMO/qGNw10wSv9QDCPfzXfyFrOaCSSoRfqE1Kf1s5an66J5JZC62NewG+mK49jOCtQew==} 692 | engines: {node: '>=4'} 693 | 694 | fast-glob@3.3.2: 695 | resolution: {integrity: sha512-oX2ruAFQwf/Orj8m737Y5adxDQO0LAB7/S5MnxCdTNDd4p6BsyIVsv9JQsATbTSq8KHRpLwIHbVlUNatxd+1Ow==} 696 | engines: {node: '>=8.6.0'} 697 | 698 | fastq@1.17.1: 699 | resolution: {integrity: sha512-sRVD3lWVIXWg6By68ZN7vho9a1pQcN/WBFaAAsDDFzlJjvoGx0P8z7V1t72grFJfJhu3YPZBuu25f7Kaw2jN1w==} 700 | 701 | fill-range@7.1.1: 702 | resolution: {integrity: sha512-YsGpe3WHLK8ZYi4tWDg2Jy3ebRz2rXowDxnld4bkQB00cc/1Zw9AWnC0i9ztDJitivtQvaI9KaLyKrc+hBW0yg==} 703 | engines: {node: '>=8'} 704 | 705 | find-up@4.1.0: 706 | resolution: {integrity: sha512-PpOwAdQ/YlXQ2vj8a3h8IipDuYRi3wceVQQGYWxNINccq40Anw7BlsEXCMbt1Zt+OLA6Fq9suIpIWD0OsnISlw==} 707 | engines: {node: '>=8'} 708 | 709 | find-up@5.0.0: 710 | resolution: {integrity: sha512-78/PXT1wlLLDgTzDs7sjq9hzz0vXD+zn+7wypEe4fXQxCmdmqfGsEPQxmiCSQI3ajFV91bVSsvNtrJRiW6nGng==} 711 | engines: {node: '>=10'} 712 | 713 | find-yarn-workspace-root2@1.2.16: 714 | resolution: {integrity: sha512-hr6hb1w8ePMpPVUK39S4RlwJzi+xPLuVuG8XlwXU3KD5Yn3qgBWVfy3AzNlDhWvE1EORCE65/Qm26rFQt3VLVA==} 715 | 716 | foreground-child@3.2.1: 717 | resolution: {integrity: sha512-PXUUyLqrR2XCWICfv6ukppP96sdFwWbNEnfEMt7jNsISjMsvaLNinAHNDYyvkyU+SZG2BTSbT5NjG+vZslfGTA==} 718 | engines: {node: '>=14'} 719 | 720 | fs-extra@7.0.1: 721 | resolution: {integrity: sha512-YJDaCJZEnBmcbw13fvdAM9AwNOJwOzrE4pqMqBq5nFiEqXUqHwlK4B+3pUw6JNvfSPtX05xFHtYy/1ni01eGCw==} 722 | engines: {node: '>=6 <7 || >=8'} 723 | 724 | fs-extra@8.1.0: 725 | resolution: {integrity: sha512-yhlQgA6mnOJUKOsRUFsgJdQCvkKhcz8tlZG5HBQfReYZy46OwLcY+Zia0mtdHsOo9y/hP+CxMN0TU9QxoOtG4g==} 726 | engines: {node: '>=6 <7 || >=8'} 727 | 728 | fsevents@2.3.3: 729 | resolution: {integrity: sha512-5xoDfX+fL7faATnagmWPpbFtwh/R77WmMMqqHGS65C3vvB0YHrgF+B1YmZ3441tMj5n63k0212XNoJwzlhffQw==} 730 | engines: {node: ^8.16.0 || ^10.6.0 || >=11.0.0} 731 | os: [darwin] 732 | 733 | get-func-name@2.0.2: 734 | resolution: {integrity: sha512-8vXOvuE167CtIc3OyItco7N/dpRtBbYOsPsXCz7X/PMnlGjYjSGuZJgM1Y7mmew7BKf9BqvLX2tnOVy1BBUsxQ==} 735 | 736 | get-stream@6.0.1: 737 | resolution: {integrity: sha512-ts6Wi+2j3jQjqi70w5AlN8DFnkSwC+MqmxEzdEALB2qXZYV3X/b1CTfgPLGJNMeAWxdPfU8FO1ms3NUfaHCPYg==} 738 | engines: {node: '>=10'} 739 | 740 | get-stream@8.0.1: 741 | resolution: {integrity: sha512-VaUJspBffn/LMCJVoMvSAdmscJyS1auj5Zulnn5UoYcY531UWmdwhRWkcGKnGU93m5HSXP9LP2usOryrBtQowA==} 742 | engines: {node: '>=16'} 743 | 744 | glob-parent@5.1.2: 745 | resolution: {integrity: sha512-AOIgSQCepiJYwP3ARnGx+5VnTu2HBYdzbGP45eLw1vr3zB3vZLeyed1sC9hnbcOc9/SrMyM5RPQrkGz4aS9Zow==} 746 | engines: {node: '>= 6'} 747 | 748 | glob@10.4.5: 749 | resolution: {integrity: sha512-7Bv8RF0k6xjo7d4A/PxYLbUCfb6c+Vpd2/mB2yRDlew7Jb5hEXiCD9ibfO7wpk8i4sevK6DFny9h7EYbM3/sHg==} 750 | hasBin: true 751 | 752 | globby@11.1.0: 753 | resolution: {integrity: sha512-jhIXaOzy1sb8IyocaruWSn1TjmnBVs8Ayhcy83rmxNJ8q2uWKCAj3CnJY+KpGSXCueAPc0i05kVvVKtP1t9S3g==} 754 | engines: {node: '>=10'} 755 | 756 | graceful-fs@4.2.11: 757 | resolution: {integrity: sha512-RbJ5/jmFcNNCcDV5o9eTnBLJ/HszWV0P73bc+Ff4nS/rJj+YaS6IGyiOL0VoBYX+l1Wrl3k63h/KrH+nhJ0XvQ==} 758 | 759 | has-flag@3.0.0: 760 | resolution: {integrity: sha512-sKJf1+ceQBr4SMkvQnBDNDtf4TXpVhVGateu0t918bl30FnbE2m4vNLX+VWe/dpjlb+HugGYzW7uQXH98HPEYw==} 761 | engines: {node: '>=4'} 762 | 763 | has-flag@4.0.0: 764 | resolution: {integrity: sha512-EykJT/Q1KjTWctppgIAgfSO0tKVuZUjhgMr17kqTumMl6Afv3EISleU7qZUzoXDFTAHTDC4NOoG/ZxU3EvlMPQ==} 765 | engines: {node: '>=8'} 766 | 767 | html-escaper@2.0.2: 768 | resolution: {integrity: sha512-H2iMtd0I4Mt5eYiapRdIDjp+XzelXQ0tFE4JS7YFwFevXXMmOp9myNrUvCg0D6ws8iqkRPBfKHgbwig1SmlLfg==} 769 | 770 | human-id@1.0.2: 771 | resolution: {integrity: sha512-UNopramDEhHJD+VR+ehk8rOslwSfByxPIZyJRfV739NDhN5LF1fa1MqnzKm2lGTQRjNrjK19Q5fhkgIfjlVUKw==} 772 | 773 | human-signals@2.1.0: 774 | resolution: {integrity: sha512-B4FFZ6q/T2jhhksgkbEW3HBvWIfDW85snkQgawt07S7J5QXTk6BkNV+0yAeZrM5QpMAdYlocGoljn0sJ/WQkFw==} 775 | engines: {node: '>=10.17.0'} 776 | 777 | human-signals@5.0.0: 778 | resolution: {integrity: sha512-AXcZb6vzzrFAUE61HnN4mpLqd/cSIwNQjtNWR0euPm6y0iqx3G4gOXaIDdtdDwZmhwe82LA6+zinmW4UBWVePQ==} 779 | engines: {node: '>=16.17.0'} 780 | 781 | iconv-lite@0.4.24: 782 | resolution: {integrity: sha512-v3MXnZAcvnywkTUEZomIActle7RXXeedOR31wwl7VlyoXO4Qi9arvSenNQWne1TcRwhCL1HwLI21bEqdpj8/rA==} 783 | engines: {node: '>=0.10.0'} 784 | 785 | ignore@5.3.1: 786 | resolution: {integrity: sha512-5Fytz/IraMjqpwfd34ke28PTVMjZjJG2MPn5t7OE4eUCUNf8BAa7b5WUS9/Qvr6mwOQS7Mk6vdsMno5he+T8Xw==} 787 | engines: {node: '>= 4'} 788 | 789 | is-binary-path@2.1.0: 790 | resolution: {integrity: sha512-ZMERYes6pDydyuGidse7OsHxtbI7WVeUEozgR/g7rd0xUimYNlvZRE/K2MgZTjWy725IfelLeVcEM97mmtRGXw==} 791 | engines: {node: '>=8'} 792 | 793 | is-extglob@2.1.1: 794 | resolution: {integrity: sha512-SbKbANkN603Vi4jEZv49LeVJMn4yGwsbzZworEoyEiutsN3nJYdbO36zfhGJ6QEDpOZIFkDtnq5JRxmvl3jsoQ==} 795 | engines: {node: '>=0.10.0'} 796 | 797 | is-fullwidth-code-point@3.0.0: 798 | resolution: {integrity: sha512-zymm5+u+sCsSWyD9qNaejV3DFvhCKclKdizYaJUuHA83RLjb7nSuGnddCHGv0hk+KY7BMAlsWeK4Ueg6EV6XQg==} 799 | engines: {node: '>=8'} 800 | 801 | is-glob@4.0.3: 802 | resolution: {integrity: sha512-xelSayHH36ZgE7ZWhli7pW34hNbNl8Ojv5KVmkJD4hBdD3th8Tfk9vYasLM+mXWOZhFkgZfxhLSnrwRr4elSSg==} 803 | engines: {node: '>=0.10.0'} 804 | 805 | is-number@7.0.0: 806 | resolution: {integrity: sha512-41Cifkg6e8TylSpdtTpeLVMqvSBEVzTttHvERD741+pnZ8ANv0004MRL43QKPDlK9cGvNp6NZWZUBlbGXYxxng==} 807 | engines: {node: '>=0.12.0'} 808 | 809 | is-stream@2.0.1: 810 | resolution: {integrity: sha512-hFoiJiTl63nn+kstHGBtewWSKnQLpyb155KHheA1l39uvtO9nWIop1p3udqPcUd/xbF1VLMO4n7OI6p7RbngDg==} 811 | engines: {node: '>=8'} 812 | 813 | is-stream@3.0.0: 814 | resolution: {integrity: sha512-LnQR4bZ9IADDRSkvpqMGvt/tEJWclzklNgSw48V5EAaAeDd6qGvN8ei6k5p0tvxSR171VmGyHuTiAOfxAbr8kA==} 815 | engines: {node: ^12.20.0 || ^14.13.1 || >=16.0.0} 816 | 817 | is-subdir@1.2.0: 818 | resolution: {integrity: sha512-2AT6j+gXe/1ueqbW6fLZJiIw3F8iXGJtt0yDrZaBhAZEG1raiTxKWU+IPqMCzQAXOUCKdA4UDMgacKH25XG2Cw==} 819 | engines: {node: '>=4'} 820 | 821 | is-windows@1.0.2: 822 | resolution: {integrity: sha512-eXK1UInq2bPmjyX6e3VHIzMLobc4J94i4AWn+Hpq3OU5KkrRC96OAcR3PRJ/pGu6m8TRnBHP9dkXQVsT/COVIA==} 823 | engines: {node: '>=0.10.0'} 824 | 825 | isexe@2.0.0: 826 | resolution: {integrity: sha512-RHxMLp9lnKHGHRng9QFhRCMbYAcVpn69smSGcq3f36xjgVVWThj4qqLbTLlq7Ssj8B+fIQ1EuCEGI2lKsyQeIw==} 827 | 828 | istanbul-lib-coverage@3.2.2: 829 | resolution: {integrity: sha512-O8dpsF+r0WV/8MNRKfnmrtCWhuKjxrq2w+jpzBL5UZKTi2LeVWnWOmWRxFlesJONmc+wLAGvKQZEOanko0LFTg==} 830 | engines: {node: '>=8'} 831 | 832 | istanbul-lib-report@3.0.1: 833 | resolution: {integrity: sha512-GCfE1mtsHGOELCU8e/Z7YWzpmybrx/+dSTfLrvY8qRmaY6zXTKWn6WQIjaAFw069icm6GVMNkgu0NzI4iPZUNw==} 834 | engines: {node: '>=10'} 835 | 836 | istanbul-lib-source-maps@5.0.6: 837 | resolution: {integrity: sha512-yg2d+Em4KizZC5niWhQaIomgf5WlL4vOOjZ5xGCmF8SnPE/mDWWXgvRExdcpCgh9lLRRa1/fSYp2ymmbJ1pI+A==} 838 | engines: {node: '>=10'} 839 | 840 | istanbul-reports@3.1.7: 841 | resolution: {integrity: sha512-BewmUXImeuRk2YY0PVbxgKAysvhRPUQE0h5QRM++nVWyubKGV0l8qQ5op8+B2DOmwSe63Jivj0BjkPQVf8fP5g==} 842 | engines: {node: '>=8'} 843 | 844 | jackspeak@3.4.2: 845 | resolution: {integrity: sha512-qH3nOSj8q/8+Eg8LUPOq3C+6HWkpUioIjDsq1+D4zY91oZvpPttw8GwtF1nReRYKXl+1AORyFqtm2f5Q1SB6/Q==} 846 | engines: {node: 14 >=14.21 || 16 >=16.20 || >=18} 847 | 848 | joycon@3.1.1: 849 | resolution: {integrity: sha512-34wB/Y7MW7bzjKRjUKTa46I2Z7eV62Rkhva+KkopW7Qvv/OSWBqvkSY7vusOPrNuZcUG3tApvdVgNB8POj3SPw==} 850 | engines: {node: '>=10'} 851 | 852 | js-yaml@3.14.1: 853 | resolution: {integrity: sha512-okMH7OXXJ7YrN9Ok3/SXrnu4iX9yOk+25nqX4imS2npuvTYDmo/QEZoqwZkYaIDk3jVvBOTOIEgEhaLOynBS9g==} 854 | hasBin: true 855 | 856 | jsonfile@4.0.0: 857 | resolution: {integrity: sha512-m6F1R3z8jjlf2imQHS2Qez5sjKWQzbuuhuJ/FKYFRZvPE3PuHcSMVZzfsLhGVOkfd20obL5SWEBew5ShlquNxg==} 858 | 859 | lilconfig@3.1.2: 860 | resolution: {integrity: sha512-eop+wDAvpItUys0FWkHIKeC9ybYrTGbU41U5K7+bttZZeohvnY7M9dZ5kB21GNWiFT2q1OoPTvncPCgSOVO5ow==} 861 | engines: {node: '>=14'} 862 | 863 | lines-and-columns@1.2.4: 864 | resolution: {integrity: sha512-7ylylesZQ/PV29jhEDl3Ufjo6ZX7gCqJr5F7PKrqc93v7fzSymt1BpwEU8nAUXs8qzzvqhbjhK5QZg6Mt/HkBg==} 865 | 866 | load-tsconfig@0.2.5: 867 | resolution: {integrity: sha512-IXO6OCs9yg8tMKzfPZ1YmheJbZCiEsnBdcB03l0OcfK9prKnJb96siuHCr5Fl37/yo9DnKU+TLpxzTUspw9shg==} 868 | engines: {node: ^12.20.0 || ^14.13.1 || >=16.0.0} 869 | 870 | load-yaml-file@0.2.0: 871 | resolution: {integrity: sha512-OfCBkGEw4nN6JLtgRidPX6QxjBQGQf72q3si2uvqyFEMbycSFFHwAZeXx6cJgFM9wmLrf9zBwCP3Ivqa+LLZPw==} 872 | engines: {node: '>=6'} 873 | 874 | locate-path@5.0.0: 875 | resolution: {integrity: sha512-t7hw9pI+WvuwNJXwk5zVHpyhIqzg2qTlklJOf0mVxGSbe3Fp2VieZcduNYjaLDoy6p9uGpQEGWG87WpMKlNq8g==} 876 | engines: {node: '>=8'} 877 | 878 | locate-path@6.0.0: 879 | resolution: {integrity: sha512-iPZK6eYjbxRu3uB4/WZ3EsEIMJFMqAoopl3R+zuq0UjcAm/MO6KCweDgPfP3elTztoKP3KtnVHxTn2NHBSDVUw==} 880 | engines: {node: '>=10'} 881 | 882 | lodash.sortby@4.7.0: 883 | resolution: {integrity: sha512-HDWXG8isMntAyRF5vZ7xKuEvOhT4AhlRt/3czTSjvGUxjYCBVRQY48ViDHyfYz9VIoBkW4TMGQNapx+l3RUwdA==} 884 | 885 | lodash.startcase@4.4.0: 886 | resolution: {integrity: sha512-+WKqsK294HMSc2jEbNgpHpd0JfIBhp7rEV4aqXWqFr6AlXov+SlcgB1Fv01y2kGe3Gc8nMW7VA0SrGuSkRfIEg==} 887 | 888 | loupe@3.1.1: 889 | resolution: {integrity: sha512-edNu/8D5MKVfGVFRhFf8aAxiTM6Wumfz5XsaatSxlD3w4R1d/WEKUTydCdPGbl9K7QG/Ca3GnDV2sIKIpXRQcw==} 890 | 891 | lru-cache@10.4.3: 892 | resolution: {integrity: sha512-JNAzZcXrCt42VGLuYz0zfAzDfAvJWW6AfYlDBQyDV5DClI2m5sAmK+OIO7s59XfsRsWHp02jAJrRadPRGTt6SQ==} 893 | 894 | lru-cache@4.1.5: 895 | resolution: {integrity: sha512-sWZlbEP2OsHNkXrMl5GYk/jKk70MBng6UU4YI/qGDYbgf6YbP4EvmqISbXCoJiRKs+1bSpFHVgQxvJ17F2li5g==} 896 | 897 | magic-string@0.30.10: 898 | resolution: {integrity: sha512-iIRwTIf0QKV3UAnYK4PU8uiEc4SRh5jX0mwpIwETPpHdhVM4f53RSwS/vXvN1JhGX+Cs7B8qIq3d6AH49O5fAQ==} 899 | 900 | magicast@0.3.4: 901 | resolution: {integrity: sha512-TyDF/Pn36bBji9rWKHlZe+PZb6Mx5V8IHCSxk7X4aljM4e/vyDvZZYwHewdVaqiA0nb3ghfHU/6AUpDxWoER2Q==} 902 | 903 | make-dir@4.0.0: 904 | resolution: {integrity: sha512-hXdUTZYIVOt1Ex//jAQi+wTZZpUpwBj/0QsOzqegb3rGMMeJiSEu5xLHnYfBrRV4RH2+OCSOO95Is/7x1WJ4bw==} 905 | engines: {node: '>=10'} 906 | 907 | merge-stream@2.0.0: 908 | resolution: {integrity: sha512-abv/qOcuPfk3URPfDzmZU1LKmuw8kT+0nIHvKrKgFrwifol/doWcdA4ZqsWQ8ENrFKkd67Mfpo/LovbIUsbt3w==} 909 | 910 | merge2@1.4.1: 911 | resolution: {integrity: sha512-8q7VEgMJW4J8tcfVPy8g09NcQwZdbwFEqhe/WZkoIzjn/3TGDwtOCYtXGxA3O8tPzpczCCDgv+P2P5y00ZJOOg==} 912 | engines: {node: '>= 8'} 913 | 914 | micromatch@4.0.7: 915 | resolution: {integrity: sha512-LPP/3KorzCwBxfeUuZmaR6bG2kdeHSbe0P2tY3FLRU4vYrjYz5hI4QZwV0njUx3jeuKe67YukQ1LSPZBKDqO/Q==} 916 | engines: {node: '>=8.6'} 917 | 918 | mimic-fn@2.1.0: 919 | resolution: {integrity: sha512-OqbOk5oEQeAZ8WXWydlu9HJjz9WVdEIvamMCcXmuqUYjTknH/sqsWvhQ3vgwKFRR1HpjvNBKQ37nbJgYzGqGcg==} 920 | engines: {node: '>=6'} 921 | 922 | mimic-fn@4.0.0: 923 | resolution: {integrity: sha512-vqiC06CuhBTUdZH+RYl8sFrL096vA45Ok5ISO6sE/Mr1jRbGH4Csnhi8f3wKVl7x8mO4Au7Ir9D3Oyv1VYMFJw==} 924 | engines: {node: '>=12'} 925 | 926 | minimatch@9.0.5: 927 | resolution: {integrity: sha512-G6T0ZX48xgozx7587koeX9Ys2NYy6Gmv//P89sEte9V9whIapMNF4idKxnW2QtCcLiTWlb/wfCabAtAFWhhBow==} 928 | engines: {node: '>=16 || 14 >=14.17'} 929 | 930 | minipass@7.1.2: 931 | resolution: {integrity: sha512-qOOzS1cBTWYF4BH8fVePDBOO9iptMnGUEZwNc/cMWnTV2nVLZ7VoNWEPHkYczZA0pdoA7dl6e7FL659nX9S2aw==} 932 | engines: {node: '>=16 || 14 >=14.17'} 933 | 934 | mri@1.2.0: 935 | resolution: {integrity: sha512-tzzskb3bG8LvYGFF/mDTpq3jpI6Q9wc3LEmBaghu+DdCssd1FakN7Bc0hVNmEyGq1bq3RgfkCb3cmQLpNPOroA==} 936 | engines: {node: '>=4'} 937 | 938 | ms@2.1.2: 939 | resolution: {integrity: sha512-sGkPx+VjMtmA6MX27oA4FBFELFCZZ4S4XqeGOXCv68tT+jb3vk/RyaKWP0PTKyWtmLSM0b+adUTEvbs1PEaH2w==} 940 | 941 | mz@2.7.0: 942 | resolution: {integrity: sha512-z81GNO7nnYMEhrGh9LeymoE4+Yr0Wn5McHIZMK5cfQCl+NDX08sCZgUc9/6MHni9IWuFLm1Z3HTCXu2z9fN62Q==} 943 | 944 | nanoid@3.3.7: 945 | resolution: {integrity: sha512-eSRppjcPIatRIMC1U6UngP8XFcz8MQWGQdt1MTBQ7NaAmvXDfvNxbvWV3x2y6CdEUciCSsDHDQZbhYaB8QEo2g==} 946 | engines: {node: ^10 || ^12 || ^13.7 || ^14 || >=15.0.1} 947 | hasBin: true 948 | 949 | normalize-path@3.0.0: 950 | resolution: {integrity: sha512-6eZs5Ls3WtCisHWp9S2GUy8dqkpGi4BVSz3GaqiE6ezub0512ESztXUwUB6C6IKbQkY2Pnb/mD4WYojCRwcwLA==} 951 | engines: {node: '>=0.10.0'} 952 | 953 | npm-run-path@4.0.1: 954 | resolution: {integrity: sha512-S48WzZW777zhNIrn7gxOlISNAqi9ZC/uQFnRdbeIHhZhCA6UqpkOT8T1G7BvfdgP4Er8gF4sUbaS0i7QvIfCWw==} 955 | engines: {node: '>=8'} 956 | 957 | npm-run-path@5.3.0: 958 | resolution: {integrity: sha512-ppwTtiJZq0O/ai0z7yfudtBpWIoxM8yE6nHi1X47eFR2EWORqfbu6CnPlNsjeN683eT0qG6H/Pyf9fCcvjnnnQ==} 959 | engines: {node: ^12.20.0 || ^14.13.1 || >=16.0.0} 960 | 961 | object-assign@4.1.1: 962 | resolution: {integrity: sha512-rJgTQnkUnH1sFw8yT6VSU3zD3sWmu6sZhIseY8VX+GRu3P6F7Fu+JNDoXfklElbLJSnc3FUQHVe4cU5hj+BcUg==} 963 | engines: {node: '>=0.10.0'} 964 | 965 | onetime@5.1.2: 966 | resolution: {integrity: sha512-kbpaSSGJTWdAY5KPVeMOKXSrPtr8C8C7wodJbcsd51jRnmD+GZu8Y0VoU6Dm5Z4vWr0Ig/1NKuWRKf7j5aaYSg==} 967 | engines: {node: '>=6'} 968 | 969 | onetime@6.0.0: 970 | resolution: {integrity: sha512-1FlR+gjXK7X+AsAHso35MnyN5KqGwJRi/31ft6x0M194ht7S+rWAvd7PHss9xSKMzE0asv1pyIHaJYq+BbacAQ==} 971 | engines: {node: '>=12'} 972 | 973 | os-tmpdir@1.0.2: 974 | resolution: {integrity: sha512-D2FR03Vir7FIu45XBY20mTb+/ZSWB00sjU9jdQXt83gDrI4Ztz5Fs7/yy74g2N5SVQY4xY1qDr4rNddwYRVX0g==} 975 | engines: {node: '>=0.10.0'} 976 | 977 | outdent@0.5.0: 978 | resolution: {integrity: sha512-/jHxFIzoMXdqPzTaCpFzAAWhpkSjZPF4Vsn6jAfNpmbH/ymsmd7Qc6VE9BGn0L6YMj6uwpQLxCECpus4ukKS9Q==} 979 | 980 | p-filter@2.1.0: 981 | resolution: {integrity: sha512-ZBxxZ5sL2HghephhpGAQdoskxplTwr7ICaehZwLIlfL6acuVgZPm8yBNuRAFBGEqtD/hmUeq9eqLg2ys9Xr/yw==} 982 | engines: {node: '>=8'} 983 | 984 | p-limit@2.3.0: 985 | resolution: {integrity: sha512-//88mFWSJx8lxCzwdAABTJL2MyWB12+eIY7MDL2SqLmAkeKU9qxRvWuSyTjm3FUmpBEMuFfckAIqEaVGUDxb6w==} 986 | engines: {node: '>=6'} 987 | 988 | p-limit@3.1.0: 989 | resolution: {integrity: sha512-TYOanM3wGwNGsZN2cVTYPArw454xnXj5qmWF1bEoAc4+cU/ol7GVh7odevjp1FNHduHc3KZMcFduxU5Xc6uJRQ==} 990 | engines: {node: '>=10'} 991 | 992 | p-locate@4.1.0: 993 | resolution: {integrity: sha512-R79ZZ/0wAxKGu3oYMlz8jy/kbhsNrS7SKZ7PxEHBgJ5+F2mtFW2fK2cOtBh1cHYkQsbzFV7I+EoRKe6Yt0oK7A==} 994 | engines: {node: '>=8'} 995 | 996 | p-locate@5.0.0: 997 | resolution: {integrity: sha512-LaNjtRWUBY++zB5nE/NwcaoMylSPk+S+ZHNB1TzdbMJMny6dynpAGt7X/tl/QYq3TIeE6nxHppbo2LGymrG5Pw==} 998 | engines: {node: '>=10'} 999 | 1000 | p-map@2.1.0: 1001 | resolution: {integrity: sha512-y3b8Kpd8OAN444hxfBbFfj1FY/RjtTd8tzYwhUqNYXx0fXx2iX4maP4Qr6qhIKbQXI02wTLAda4fYUbDagTUFw==} 1002 | engines: {node: '>=6'} 1003 | 1004 | p-try@2.2.0: 1005 | resolution: {integrity: sha512-R4nPAVTAU0B9D35/Gk3uJf/7XYbQcyohSKdvAxIRSNghFl4e71hVoGnBNQz9cWaXxO2I10KTC+3jMdvvoKw6dQ==} 1006 | engines: {node: '>=6'} 1007 | 1008 | package-json-from-dist@1.0.0: 1009 | resolution: {integrity: sha512-dATvCeZN/8wQsGywez1mzHtTlP22H8OEfPrVMLNr4/eGa+ijtLn/6M5f0dY8UKNrC2O9UCU6SSoG3qRKnt7STw==} 1010 | 1011 | path-exists@4.0.0: 1012 | resolution: {integrity: sha512-ak9Qy5Q7jYb2Wwcey5Fpvg2KoAc/ZIhLSLOSBmRmygPsGwkVVt0fZa0qrtMz+m6tJTAHfZQ8FnmB4MG4LWy7/w==} 1013 | engines: {node: '>=8'} 1014 | 1015 | path-key@3.1.1: 1016 | resolution: {integrity: sha512-ojmeN0qd+y0jszEtoY48r0Peq5dwMEkIlCOu6Q5f41lfkswXuKtYrhgoTpLnyIcHm24Uhqx+5Tqm2InSwLhE6Q==} 1017 | engines: {node: '>=8'} 1018 | 1019 | path-key@4.0.0: 1020 | resolution: {integrity: sha512-haREypq7xkM7ErfgIyA0z+Bj4AGKlMSdlQE2jvJo6huWD1EdkKYV+G/T4nq0YEF2vgTT8kqMFKo1uHn950r4SQ==} 1021 | engines: {node: '>=12'} 1022 | 1023 | path-scurry@1.11.1: 1024 | resolution: {integrity: sha512-Xa4Nw17FS9ApQFJ9umLiJS4orGjm7ZzwUrwamcGQuHSzDyth9boKDaycYdDcZDuqYATXw4HFXgaqWTctW/v1HA==} 1025 | engines: {node: '>=16 || 14 >=14.18'} 1026 | 1027 | path-type@4.0.0: 1028 | resolution: {integrity: sha512-gDKb8aZMDeD/tZWs9P6+q0J9Mwkdl6xMV8TjnGP3qJVJ06bdMgkbBlLU8IdfOsIsFz2BW1rNVT3XuNEl8zPAvw==} 1029 | engines: {node: '>=8'} 1030 | 1031 | pathe@1.1.2: 1032 | resolution: {integrity: sha512-whLdWMYL2TwI08hn8/ZqAbrVemu0LNaNNJZX73O6qaIdCTfXutsLhMkjdENX0qhsQ9uIimo4/aQOmXkoon2nDQ==} 1033 | 1034 | pathval@2.0.0: 1035 | resolution: {integrity: sha512-vE7JKRyES09KiunauX7nd2Q9/L7lhok4smP9RZTDeD4MVs72Dp2qNFVz39Nz5a0FVEW0BJR6C0DYrq6unoziZA==} 1036 | engines: {node: '>= 14.16'} 1037 | 1038 | picocolors@1.0.1: 1039 | resolution: {integrity: sha512-anP1Z8qwhkbmu7MFP5iTt+wQKXgwzf7zTyGlcdzabySa9vd0Xt392U0rVmz9poOaBj0uHJKyyo9/upk0HrEQew==} 1040 | 1041 | picomatch@2.3.1: 1042 | resolution: {integrity: sha512-JU3teHTNjmE2VCGFzuY8EXzCDVwEqB2a8fsIvwaStHhAWJEeVd1o1QD80CU6+ZdEXXSLbSsuLwJjkCBWqRQUVA==} 1043 | engines: {node: '>=8.6'} 1044 | 1045 | pify@4.0.1: 1046 | resolution: {integrity: sha512-uB80kBFb/tfd68bVleG9T5GGsGPjJrLAUpR5PZIrhBnIaRTQRjqdJSsIKkOP6OAIFbj7GOrcudc5pNjZ+geV2g==} 1047 | engines: {node: '>=6'} 1048 | 1049 | pirates@4.0.6: 1050 | resolution: {integrity: sha512-saLsH7WeYYPiD25LDuLRRY/i+6HaPYr6G1OUlN39otzkSTxKnubR9RTxS3/Kk50s1g2JTgFwWQDQyplC5/SHZg==} 1051 | engines: {node: '>= 6'} 1052 | 1053 | pkg-dir@4.2.0: 1054 | resolution: {integrity: sha512-HRDzbaKjC+AOWVXxAU/x54COGeIv9eb+6CkDSQoNTt4XyWoIJvuPsXizxu/Fr23EiekbtZwmh1IcIG/l/a10GQ==} 1055 | engines: {node: '>=8'} 1056 | 1057 | postcss-load-config@4.0.2: 1058 | resolution: {integrity: sha512-bSVhyJGL00wMVoPUzAVAnbEoWyqRxkjv64tUl427SKnPrENtq6hJwUojroMz2VB+Q1edmi4IfrAPpami5VVgMQ==} 1059 | engines: {node: '>= 14'} 1060 | peerDependencies: 1061 | postcss: '>=8.0.9' 1062 | ts-node: '>=9.0.0' 1063 | peerDependenciesMeta: 1064 | postcss: 1065 | optional: true 1066 | ts-node: 1067 | optional: true 1068 | 1069 | postcss@8.4.39: 1070 | resolution: {integrity: sha512-0vzE+lAiG7hZl1/9I8yzKLx3aR9Xbof3fBHKunvMfOCYAtMhrsnccJY2iTURb9EZd5+pLuiNV9/c/GZJOHsgIw==} 1071 | engines: {node: ^10 || ^12 || >=14} 1072 | 1073 | preferred-pm@3.1.4: 1074 | resolution: {integrity: sha512-lEHd+yEm22jXdCphDrkvIJQU66EuLojPPtvZkpKIkiD+l0DMThF/niqZKJSoU8Vl7iuvtmzyMhir9LdVy5WMnA==} 1075 | engines: {node: '>=10'} 1076 | 1077 | prettier@2.8.8: 1078 | resolution: {integrity: sha512-tdN8qQGvNjw4CHbY+XXk0JgCXn9QiF21a55rBe5LJAU+kDyC4WQn4+awm2Xfk2lQMk5fKup9XgzTZtGkjBdP9Q==} 1079 | engines: {node: '>=10.13.0'} 1080 | hasBin: true 1081 | 1082 | pseudomap@1.0.2: 1083 | resolution: {integrity: sha512-b/YwNhb8lk1Zz2+bXXpS/LK9OisiZZ1SNsSLxN1x2OXVEhW2Ckr/7mWE5vrC1ZTiJlD9g19jWszTmJsB+oEpFQ==} 1084 | 1085 | punycode@2.3.1: 1086 | resolution: {integrity: sha512-vYt7UD1U9Wg6138shLtLOvdAu+8DsC/ilFtEVHcH+wydcSpNE20AfSOduf6MkRFahL5FY7X1oU7nKVZFtfq8Fg==} 1087 | engines: {node: '>=6'} 1088 | 1089 | queue-microtask@1.2.3: 1090 | resolution: {integrity: sha512-NuaNSa6flKT5JaSYQzJok04JzTL1CA6aGhv5rfLW3PgqA+M2ChpZQnAC8h8i4ZFkBS8X5RqkDBHA7r4hej3K9A==} 1091 | 1092 | read-yaml-file@1.1.0: 1093 | resolution: {integrity: sha512-VIMnQi/Z4HT2Fxuwg5KrY174U1VdUIASQVWXXyqtNRtxSr9IYkn1rsI6Tb6HsrHCmB7gVpNwX6JxPTHcH6IoTA==} 1094 | engines: {node: '>=6'} 1095 | 1096 | readdirp@3.6.0: 1097 | resolution: {integrity: sha512-hOS089on8RduqdbhvQ5Z37A0ESjsqz6qnRcffsMU3495FuTdqSm+7bhJ29JvIOsBDEEnan5DPu9t3To9VRlMzA==} 1098 | engines: {node: '>=8.10.0'} 1099 | 1100 | regenerator-runtime@0.14.1: 1101 | resolution: {integrity: sha512-dYnhHh0nJoMfnkZs6GmmhFknAGRrLznOu5nc9ML+EJxGvrx6H7teuevqVqCuPcPK//3eDrrjQhehXVx9cnkGdw==} 1102 | 1103 | resolve-from@5.0.0: 1104 | resolution: {integrity: sha512-qYg9KP24dD5qka9J47d0aVky0N+b4fTU89LN9iDnjB5waksiC49rvMB0PrUJQGoTmH50XPiqOvAjDfaijGxYZw==} 1105 | engines: {node: '>=8'} 1106 | 1107 | reusify@1.0.4: 1108 | resolution: {integrity: sha512-U9nH88a3fc/ekCF1l0/UP1IosiuIjyTh7hBvXVMHYgVcfGvt897Xguj2UOLDeI5BG2m7/uwyaLVT6fbtCwTyzw==} 1109 | engines: {iojs: '>=1.0.0', node: '>=0.10.0'} 1110 | 1111 | rollup@4.18.1: 1112 | resolution: {integrity: sha512-Elx2UT8lzxxOXMpy5HWQGZqkrQOtrVDDa/bm9l10+U4rQnVzbL/LgZ4NOM1MPIDyHk69W4InuYDF5dzRh4Kw1A==} 1113 | engines: {node: '>=18.0.0', npm: '>=8.0.0'} 1114 | hasBin: true 1115 | 1116 | run-parallel@1.2.0: 1117 | resolution: {integrity: sha512-5l4VyZR86LZ/lDxZTR6jqL8AFE2S0IFLMP26AbjsLVADxHdhB/c0GUsH+y39UfCi3dzz8OlQuPmnaJOMoDHQBA==} 1118 | 1119 | safer-buffer@2.1.2: 1120 | resolution: {integrity: sha512-YZo3K82SD7Riyi0E1EQPojLz7kpepnSQI9IyPbHHg1XXXevb5dJI7tpyN2ADxGcQbHG7vcyRHk0cbwqcQriUtg==} 1121 | 1122 | semver@7.6.3: 1123 | resolution: {integrity: sha512-oVekP1cKtI+CTDvHWYFUcMtsK/00wmAEfyqKfNdARm8u1wNVhSgaX7A8d4UuIlUI5e84iEwOhs7ZPYRmzU9U6A==} 1124 | engines: {node: '>=10'} 1125 | hasBin: true 1126 | 1127 | shebang-command@1.2.0: 1128 | resolution: {integrity: sha512-EV3L1+UQWGor21OmnvojK36mhg+TyIKDh3iFBKBohr5xeXIhNBcx8oWdgkTEEQ+BEFFYdLRuqMfd5L84N1V5Vg==} 1129 | engines: {node: '>=0.10.0'} 1130 | 1131 | shebang-command@2.0.0: 1132 | resolution: {integrity: sha512-kHxr2zZpYtdmrN1qDjrrX/Z1rR1kG8Dx+gkpK1G4eXmvXswmcE1hTWBWYUzlraYw1/yZp6YuDY77YtvbN0dmDA==} 1133 | engines: {node: '>=8'} 1134 | 1135 | shebang-regex@1.0.0: 1136 | resolution: {integrity: sha512-wpoSFAxys6b2a2wHZ1XpDSgD7N9iVjg29Ph9uV/uaP9Ex/KXlkTZTeddxDPSYQpgvzKLGJke2UU0AzoGCjNIvQ==} 1137 | engines: {node: '>=0.10.0'} 1138 | 1139 | shebang-regex@3.0.0: 1140 | resolution: {integrity: sha512-7++dFhtcx3353uBaq8DDR4NuxBetBzC7ZQOhmTQInHEd6bSrXdiEyzCvG07Z44UYdLShWUyXt5M/yhz8ekcb1A==} 1141 | engines: {node: '>=8'} 1142 | 1143 | siginfo@2.0.0: 1144 | resolution: {integrity: sha512-ybx0WO1/8bSBLEWXZvEd7gMW3Sn3JFlW3TvX1nREbDLRNQNaeNN8WK0meBwPdAaOI7TtRRRJn/Es1zhrrCHu7g==} 1145 | 1146 | signal-exit@3.0.7: 1147 | resolution: {integrity: sha512-wnD2ZE+l+SPC/uoS0vXeE9L1+0wuaMqKlfz9AMUo38JsyLSBWSFcHR1Rri62LZc12vLr1gb3jl7iwQhgwpAbGQ==} 1148 | 1149 | signal-exit@4.1.0: 1150 | resolution: {integrity: sha512-bzyZ1e88w9O1iNJbKnOlvYTrWPDl46O1bG0D3XInv+9tkPrxrN8jUUTiFlDkkmKWgn1M6CfIA13SuGqOa9Korw==} 1151 | engines: {node: '>=14'} 1152 | 1153 | slash@3.0.0: 1154 | resolution: {integrity: sha512-g9Q1haeby36OSStwb4ntCGGGaKsaVSjQ68fBxoQcutl5fS1vuY18H3wSt3jFyFtrkx+Kz0V1G85A4MyAdDMi2Q==} 1155 | engines: {node: '>=8'} 1156 | 1157 | source-map-js@1.2.0: 1158 | resolution: {integrity: sha512-itJW8lvSA0TXEphiRoawsCksnlf8SyvmFzIhltqAHluXd88pkCd+cXJVHTDwdCr0IzwptSm035IHQktUu1QUMg==} 1159 | engines: {node: '>=0.10.0'} 1160 | 1161 | source-map-support@0.5.21: 1162 | resolution: {integrity: sha512-uBHU3L3czsIyYXKX88fdrGovxdSCoTGDRZ6SYXtSRxLZUzHg5P/66Ht6uoUlHu9EZod+inXhKo3qQgwXUT/y1w==} 1163 | 1164 | source-map@0.6.1: 1165 | resolution: {integrity: sha512-UjgapumWlbMhkBgzT7Ykc5YXUT46F0iKu8SGXq0bcwP5dz/h0Plj6enJqjz1Zbq2l5WaqYnrVbwWOWMyF3F47g==} 1166 | engines: {node: '>=0.10.0'} 1167 | 1168 | source-map@0.8.0-beta.0: 1169 | resolution: {integrity: sha512-2ymg6oRBpebeZi9UUNsgQ89bhx01TcTkmNTGnNO88imTmbSgy4nfujrgVEFKWpMTEGA11EDkTt7mqObTPdigIA==} 1170 | engines: {node: '>= 8'} 1171 | 1172 | spawndamnit@2.0.0: 1173 | resolution: {integrity: sha512-j4JKEcncSjFlqIwU5L/rp2N5SIPsdxaRsIv678+TZxZ0SRDJTm8JrxJMjE/XuiEZNEir3S8l0Fa3Ke339WI4qA==} 1174 | 1175 | sprintf-js@1.0.3: 1176 | resolution: {integrity: sha512-D9cPgkvLlV3t3IzL0D0YLvGA9Ahk4PcvVwUbN0dSGr1aP0Nrt4AEnTUbuGvquEC0mA64Gqt1fzirlRs5ibXx8g==} 1177 | 1178 | stackback@0.0.2: 1179 | resolution: {integrity: sha512-1XMJE5fQo1jGH6Y/7ebnwPOBEkIEnT4QF32d5R1+VXdXveM0IBMJt8zfaxX1P3QhVwrYe+576+jkANtSS2mBbw==} 1180 | 1181 | std-env@3.7.0: 1182 | resolution: {integrity: sha512-JPbdCEQLj1w5GilpiHAx3qJvFndqybBysA3qUOnznweH4QbNYUsW/ea8QzSrnh0vNsezMMw5bcVool8lM0gwzg==} 1183 | 1184 | string-width@4.2.3: 1185 | resolution: {integrity: sha512-wKyQRQpjJ0sIp62ErSZdGsjMJWsap5oRNihHhu6G7JVO/9jIB6UyevL+tXuOqrng8j/cxKTWyWUwvSTriiZz/g==} 1186 | engines: {node: '>=8'} 1187 | 1188 | string-width@5.1.2: 1189 | resolution: {integrity: sha512-HnLOCR3vjcY8beoNLtcjZ5/nxn2afmME6lhrDrebokqMap+XbeW8n9TXpPDOqdGK5qcI3oT0GKTW6wC7EMiVqA==} 1190 | engines: {node: '>=12'} 1191 | 1192 | strip-ansi@6.0.1: 1193 | resolution: {integrity: sha512-Y38VPSHcqkFrCpFnQ9vuSXmquuv5oXOKpGeT6aGrr3o3Gc9AlVa6JBfUSOCnbxGGZF+/0ooI7KrPuUSztUdU5A==} 1194 | engines: {node: '>=8'} 1195 | 1196 | strip-ansi@7.1.0: 1197 | resolution: {integrity: sha512-iq6eVVI64nQQTRYq2KtEg2d2uU7LElhTJwsH4YzIHZshxlgZms/wIc4VoDQTlG/IvVIrBKG06CrZnp0qv7hkcQ==} 1198 | engines: {node: '>=12'} 1199 | 1200 | strip-bom@3.0.0: 1201 | resolution: {integrity: sha512-vavAMRXOgBVNF6nyEEmL3DBK19iRpDcoIwW+swQ+CbGiu7lju6t+JklA1MHweoWtadgt4ISVUsXLyDq34ddcwA==} 1202 | engines: {node: '>=4'} 1203 | 1204 | strip-final-newline@2.0.0: 1205 | resolution: {integrity: sha512-BrpvfNAE3dcvq7ll3xVumzjKjZQ5tI1sEUIKr3Uoks0XUl45St3FlatVqef9prk4jRDzhW6WZg+3bk93y6pLjA==} 1206 | engines: {node: '>=6'} 1207 | 1208 | strip-final-newline@3.0.0: 1209 | resolution: {integrity: sha512-dOESqjYr96iWYylGObzd39EuNTa5VJxyvVAEm5Jnh7KGo75V43Hk1odPQkNDyXNmUR6k+gEiDVXnjB8HJ3crXw==} 1210 | engines: {node: '>=12'} 1211 | 1212 | sucrase@3.35.0: 1213 | resolution: {integrity: sha512-8EbVDiu9iN/nESwxeSxDKe0dunta1GOlHufmSSXxMD2z2/tMZpDMpvXQGsc+ajGo8y2uYUmixaSRUc/QPoQ0GA==} 1214 | engines: {node: '>=16 || 14 >=14.17'} 1215 | hasBin: true 1216 | 1217 | supports-color@5.5.0: 1218 | resolution: {integrity: sha512-QjVjwdXIt408MIiAqCX4oUKsgU2EqAGzs2Ppkm4aQYbjm+ZEWEcW4SfFNTr4uMNZma0ey4f5lgLrkB0aX0QMow==} 1219 | engines: {node: '>=4'} 1220 | 1221 | supports-color@7.2.0: 1222 | resolution: {integrity: sha512-qpCAvRl9stuOHveKsn7HncJRvv501qIacKzQlO/+Lwxc9+0q2wLyv4Dfvt80/DPn2pqOBsJdDiogXGR9+OvwRw==} 1223 | engines: {node: '>=8'} 1224 | 1225 | term-size@2.2.1: 1226 | resolution: {integrity: sha512-wK0Ri4fOGjv/XPy8SBHZChl8CM7uMc5VML7SqiQ0zG7+J5Vr+RMQDoHa2CNT6KHUnTGIXH34UDMkPzAUyapBZg==} 1227 | engines: {node: '>=8'} 1228 | 1229 | terser@5.31.2: 1230 | resolution: {integrity: sha512-LGyRZVFm/QElZHy/CPr/O4eNZOZIzsrQ92y4v9UJe/pFJjypje2yI3C2FmPtvUEnhadlSbmG2nXtdcjHOjCfxw==} 1231 | engines: {node: '>=10'} 1232 | hasBin: true 1233 | 1234 | test-exclude@7.0.1: 1235 | resolution: {integrity: sha512-pFYqmTw68LXVjeWJMST4+borgQP2AyMNbg1BpZh9LbyhUeNkeaPF9gzfPGUAnSMV3qPYdWUwDIjjCLiSDOl7vg==} 1236 | engines: {node: '>=18'} 1237 | 1238 | thenify-all@1.6.0: 1239 | resolution: {integrity: sha512-RNxQH/qI8/t3thXJDwcstUO4zeqo64+Uy/+sNVRBx4Xn2OX+OZ9oP+iJnNFqplFra2ZUVeKCSa2oVWi3T4uVmA==} 1240 | engines: {node: '>=0.8'} 1241 | 1242 | thenify@3.3.1: 1243 | resolution: {integrity: sha512-RVZSIV5IG10Hk3enotrhvz0T9em6cyHBLkH/YAZuKqd8hRkKhSfCGIcP2KUY0EPxndzANBmNllzWPwak+bheSw==} 1244 | 1245 | tinybench@2.8.0: 1246 | resolution: {integrity: sha512-1/eK7zUnIklz4JUUlL+658n58XO2hHLQfSk1Zf2LKieUjxidN16eKFEoDEfjHc3ohofSSqK3X5yO6VGb6iW8Lw==} 1247 | 1248 | tinypool@1.0.0: 1249 | resolution: {integrity: sha512-KIKExllK7jp3uvrNtvRBYBWBOAXSX8ZvoaD8T+7KB/QHIuoJW3Pmr60zucywjAlMb5TeXUkcs/MWeWLu0qvuAQ==} 1250 | engines: {node: ^18.0.0 || >=20.0.0} 1251 | 1252 | tinyrainbow@1.2.0: 1253 | resolution: {integrity: sha512-weEDEq7Z5eTHPDh4xjX789+fHfF+P8boiFB+0vbWzpbnbsEr/GRaohi/uMKxg8RZMXnl1ItAi/IUHWMsjDV7kQ==} 1254 | engines: {node: '>=14.0.0'} 1255 | 1256 | tinyspy@3.0.0: 1257 | resolution: {integrity: sha512-q5nmENpTHgiPVd1cJDDc9cVoYN5x4vCvwT3FMilvKPKneCBZAxn2YWQjDF0UMcE9k0Cay1gBiDfTMU0g+mPMQA==} 1258 | engines: {node: '>=14.0.0'} 1259 | 1260 | tmp@0.0.33: 1261 | resolution: {integrity: sha512-jRCJlojKnZ3addtTOjdIqoRuPEKBvNXcGYqzO6zWZX8KfKEpnGY5jfggJQ3EjKuu8D4bJRr0y+cYJFmYbImXGw==} 1262 | engines: {node: '>=0.6.0'} 1263 | 1264 | to-fast-properties@2.0.0: 1265 | resolution: {integrity: sha512-/OaKK0xYrs3DmxRYqL/yDc+FxFUVYhDlXMhRmv3z915w2HF1tnN1omB354j8VUGO/hbRzyD6Y3sA7v7GS/ceog==} 1266 | engines: {node: '>=4'} 1267 | 1268 | to-regex-range@5.0.1: 1269 | resolution: {integrity: sha512-65P7iz6X5yEr1cwcgvQxbbIw7Uk3gOy5dIdtZ4rDveLqhrdJP+Li/Hx6tyK0NEb+2GCyneCMJiGqrADCSNk8sQ==} 1270 | engines: {node: '>=8.0'} 1271 | 1272 | tr46@1.0.1: 1273 | resolution: {integrity: sha512-dTpowEjclQ7Kgx5SdBkqRzVhERQXov8/l9Ft9dVM9fmg0W0KQSVaXX9T4i6twCPNtYiZM53lpSSUAwJbFPOHxA==} 1274 | 1275 | tree-kill@1.2.2: 1276 | resolution: {integrity: sha512-L0Orpi8qGpRG//Nd+H90vFB+3iHnue1zSSGmNOOCh1GLJ7rUKVwV2HvijphGQS2UmhUZewS9VgvxYIdgr+fG1A==} 1277 | hasBin: true 1278 | 1279 | ts-interface-checker@0.1.13: 1280 | resolution: {integrity: sha512-Y/arvbn+rrz3JCKl9C4kVNfTfSm2/mEp5FSz5EsZSANGPSlQrpRI5M4PKF+mJnE52jOO90PnPSc3Ur3bTQw0gA==} 1281 | 1282 | tsup@8.1.0: 1283 | resolution: {integrity: sha512-UFdfCAXukax+U6KzeTNO2kAARHcWxmKsnvSPXUcfA1D+kU05XDccCrkffCQpFaWDsZfV0jMyTsxU39VfCp6EOg==} 1284 | engines: {node: '>=18'} 1285 | hasBin: true 1286 | peerDependencies: 1287 | '@microsoft/api-extractor': ^7.36.0 1288 | '@swc/core': ^1 1289 | postcss: ^8.4.12 1290 | typescript: '>=4.5.0' 1291 | peerDependenciesMeta: 1292 | '@microsoft/api-extractor': 1293 | optional: true 1294 | '@swc/core': 1295 | optional: true 1296 | postcss: 1297 | optional: true 1298 | typescript: 1299 | optional: true 1300 | 1301 | typescript@5.5.3: 1302 | resolution: {integrity: sha512-/hreyEujaB0w76zKo6717l3L0o/qEUtRgdvUBvlkhoWeOVMjMuHNHk0BRBzikzuGDqNmPQbg5ifMEqsHLiIUcQ==} 1303 | engines: {node: '>=14.17'} 1304 | hasBin: true 1305 | 1306 | undici-types@5.26.5: 1307 | resolution: {integrity: sha512-JlCMO+ehdEIKqlFxk6IfVoAUVmgz7cU7zD/h9XZ0qzeosSHmUJVOzSQvvYSYWXkFXC+IfLKSIffhv0sVZup6pA==} 1308 | 1309 | universalify@0.1.2: 1310 | resolution: {integrity: sha512-rBJeI5CXAlmy1pV+617WB9J63U6XcazHHF2f2dbJix4XzpUF0RS3Zbj0FGIOCAva5P/d/GBOYaACQ1w+0azUkg==} 1311 | engines: {node: '>= 4.0.0'} 1312 | 1313 | vite-node@2.0.5: 1314 | resolution: {integrity: sha512-LdsW4pxj0Ot69FAoXZ1yTnA9bjGohr2yNBU7QKRxpz8ITSkhuDl6h3zS/tvgz4qrNjeRnvrWeXQ8ZF7Um4W00Q==} 1315 | engines: {node: ^18.0.0 || >=20.0.0} 1316 | hasBin: true 1317 | 1318 | vite@5.3.3: 1319 | resolution: {integrity: sha512-NPQdeCU0Dv2z5fu+ULotpuq5yfCS1BzKUIPhNbP3YBfAMGJXbt2nS+sbTFu+qchaqWTD+H3JK++nRwr6XIcp6A==} 1320 | engines: {node: ^18.0.0 || >=20.0.0} 1321 | hasBin: true 1322 | peerDependencies: 1323 | '@types/node': ^18.0.0 || >=20.0.0 1324 | less: '*' 1325 | lightningcss: ^1.21.0 1326 | sass: '*' 1327 | stylus: '*' 1328 | sugarss: '*' 1329 | terser: ^5.4.0 1330 | peerDependenciesMeta: 1331 | '@types/node': 1332 | optional: true 1333 | less: 1334 | optional: true 1335 | lightningcss: 1336 | optional: true 1337 | sass: 1338 | optional: true 1339 | stylus: 1340 | optional: true 1341 | sugarss: 1342 | optional: true 1343 | terser: 1344 | optional: true 1345 | 1346 | vitest@2.0.5: 1347 | resolution: {integrity: sha512-8GUxONfauuIdeSl5f9GTgVEpg5BTOlplET4WEDaeY2QBiN8wSm68vxN/tb5z405OwppfoCavnwXafiaYBC/xOA==} 1348 | engines: {node: ^18.0.0 || >=20.0.0} 1349 | hasBin: true 1350 | peerDependencies: 1351 | '@edge-runtime/vm': '*' 1352 | '@types/node': ^18.0.0 || >=20.0.0 1353 | '@vitest/browser': 2.0.5 1354 | '@vitest/ui': 2.0.5 1355 | happy-dom: '*' 1356 | jsdom: '*' 1357 | peerDependenciesMeta: 1358 | '@edge-runtime/vm': 1359 | optional: true 1360 | '@types/node': 1361 | optional: true 1362 | '@vitest/browser': 1363 | optional: true 1364 | '@vitest/ui': 1365 | optional: true 1366 | happy-dom: 1367 | optional: true 1368 | jsdom: 1369 | optional: true 1370 | 1371 | webidl-conversions@4.0.2: 1372 | resolution: {integrity: sha512-YQ+BmxuTgd6UXZW3+ICGfyqRyHXVlD5GtQr5+qjiNW7bF0cqrzX500HVXPBOvgXb5YnzDd+h0zqyv61KUD7+Sg==} 1373 | 1374 | whatwg-url@7.1.0: 1375 | resolution: {integrity: sha512-WUu7Rg1DroM7oQvGWfOiAK21n74Gg+T4elXEQYkOhtyLeWiJFoOGLXPKI/9gzIie9CtwVLm8wtw6YJdKyxSjeg==} 1376 | 1377 | which-pm@2.2.0: 1378 | resolution: {integrity: sha512-MOiaDbA5ZZgUjkeMWM5EkJp4loW5ZRoa5bc3/aeMox/PJelMhE6t7S/mLuiY43DBupyxH+S0U1bTui9kWUlmsw==} 1379 | engines: {node: '>=8.15'} 1380 | 1381 | which@1.3.1: 1382 | resolution: {integrity: sha512-HxJdYWq1MTIQbJ3nw0cqssHoTNU267KlrDuGZ1WYlxDStUtKUhOaJmh112/TZmHxxUfuJqPXSOm7tDyas0OSIQ==} 1383 | hasBin: true 1384 | 1385 | which@2.0.2: 1386 | resolution: {integrity: sha512-BLI3Tl1TW3Pvl70l3yq3Y64i+awpwXqsGBYWkkqMtnbXgrMD+yj7rhW0kuEDxzJaYXGjEW5ogapKNMEKNMjibA==} 1387 | engines: {node: '>= 8'} 1388 | hasBin: true 1389 | 1390 | why-is-node-running@2.3.0: 1391 | resolution: {integrity: sha512-hUrmaWBdVDcxvYqnyh09zunKzROWjbZTiNy8dBEjkS7ehEDQibXJ7XvlmtbwuTclUiIyN+CyXQD4Vmko8fNm8w==} 1392 | engines: {node: '>=8'} 1393 | hasBin: true 1394 | 1395 | wrap-ansi@7.0.0: 1396 | resolution: {integrity: sha512-YVGIj2kamLSTxw6NsZjoBxfSwsn0ycdesmc4p+Q21c5zPuZ1pl+NfxVdxPtdHvmNVOQ6XSYG4AUtyt/Fi7D16Q==} 1397 | engines: {node: '>=10'} 1398 | 1399 | wrap-ansi@8.1.0: 1400 | resolution: {integrity: sha512-si7QWI6zUMq56bESFvagtmzMdGOtoxfR+Sez11Mobfc7tm+VkUckk9bW2UeffTGVUbOksxmSw0AA2gs8g71NCQ==} 1401 | engines: {node: '>=12'} 1402 | 1403 | yallist@2.1.2: 1404 | resolution: {integrity: sha512-ncTzHV7NvsQZkYe1DW7cbDLm0YpzHmZF5r/iyP3ZnQtMiJ+pjzisCiMNI+Sj+xQF5pXhSHxSB3uDbsBTzY/c2A==} 1405 | 1406 | yaml@2.4.5: 1407 | resolution: {integrity: sha512-aBx2bnqDzVOyNKfsysjA2ms5ZlnjSAW2eG3/L5G/CSujfjLJTJsEw1bGw8kCf04KodQWk1pxlGnZ56CRxiawmg==} 1408 | engines: {node: '>= 14'} 1409 | hasBin: true 1410 | 1411 | yocto-queue@0.1.0: 1412 | resolution: {integrity: sha512-rVksvsnNCdJ/ohGc6xgPwyN8eheCxsiLM8mxuE/t/mOVqJewPuO1miLpTHQiRgTKCLexL4MeAFVagts7HmNZ2Q==} 1413 | engines: {node: '>=10'} 1414 | 1415 | snapshots: 1416 | 1417 | '@ampproject/remapping@2.3.0': 1418 | dependencies: 1419 | '@jridgewell/gen-mapping': 0.3.5 1420 | '@jridgewell/trace-mapping': 0.3.25 1421 | 1422 | '@babel/helper-string-parser@7.24.8': {} 1423 | 1424 | '@babel/helper-validator-identifier@7.24.7': {} 1425 | 1426 | '@babel/parser@7.25.3': 1427 | dependencies: 1428 | '@babel/types': 7.25.2 1429 | 1430 | '@babel/runtime@7.25.0': 1431 | dependencies: 1432 | regenerator-runtime: 0.14.1 1433 | 1434 | '@babel/types@7.25.2': 1435 | dependencies: 1436 | '@babel/helper-string-parser': 7.24.8 1437 | '@babel/helper-validator-identifier': 7.24.7 1438 | to-fast-properties: 2.0.0 1439 | 1440 | '@bcoe/v8-coverage@0.2.3': {} 1441 | 1442 | '@changesets/apply-release-plan@7.0.4': 1443 | dependencies: 1444 | '@babel/runtime': 7.25.0 1445 | '@changesets/config': 3.0.2 1446 | '@changesets/get-version-range-type': 0.4.0 1447 | '@changesets/git': 3.0.0 1448 | '@changesets/should-skip-package': 0.1.0 1449 | '@changesets/types': 6.0.0 1450 | '@manypkg/get-packages': 1.1.3 1451 | detect-indent: 6.1.0 1452 | fs-extra: 7.0.1 1453 | lodash.startcase: 4.4.0 1454 | outdent: 0.5.0 1455 | prettier: 2.8.8 1456 | resolve-from: 5.0.0 1457 | semver: 7.6.3 1458 | 1459 | '@changesets/assemble-release-plan@6.0.3': 1460 | dependencies: 1461 | '@babel/runtime': 7.25.0 1462 | '@changesets/errors': 0.2.0 1463 | '@changesets/get-dependents-graph': 2.1.1 1464 | '@changesets/should-skip-package': 0.1.0 1465 | '@changesets/types': 6.0.0 1466 | '@manypkg/get-packages': 1.1.3 1467 | semver: 7.6.3 1468 | 1469 | '@changesets/changelog-git@0.2.0': 1470 | dependencies: 1471 | '@changesets/types': 6.0.0 1472 | 1473 | '@changesets/cli@2.27.7': 1474 | dependencies: 1475 | '@babel/runtime': 7.25.0 1476 | '@changesets/apply-release-plan': 7.0.4 1477 | '@changesets/assemble-release-plan': 6.0.3 1478 | '@changesets/changelog-git': 0.2.0 1479 | '@changesets/config': 3.0.2 1480 | '@changesets/errors': 0.2.0 1481 | '@changesets/get-dependents-graph': 2.1.1 1482 | '@changesets/get-release-plan': 4.0.3 1483 | '@changesets/git': 3.0.0 1484 | '@changesets/logger': 0.1.0 1485 | '@changesets/pre': 2.0.0 1486 | '@changesets/read': 0.6.0 1487 | '@changesets/should-skip-package': 0.1.0 1488 | '@changesets/types': 6.0.0 1489 | '@changesets/write': 0.3.1 1490 | '@manypkg/get-packages': 1.1.3 1491 | '@types/semver': 7.5.8 1492 | ansi-colors: 4.1.3 1493 | chalk: 2.4.2 1494 | ci-info: 3.9.0 1495 | enquirer: 2.4.1 1496 | external-editor: 3.1.0 1497 | fs-extra: 7.0.1 1498 | human-id: 1.0.2 1499 | mri: 1.2.0 1500 | outdent: 0.5.0 1501 | p-limit: 2.3.0 1502 | preferred-pm: 3.1.4 1503 | resolve-from: 5.0.0 1504 | semver: 7.6.3 1505 | spawndamnit: 2.0.0 1506 | term-size: 2.2.1 1507 | 1508 | '@changesets/config@3.0.2': 1509 | dependencies: 1510 | '@changesets/errors': 0.2.0 1511 | '@changesets/get-dependents-graph': 2.1.1 1512 | '@changesets/logger': 0.1.0 1513 | '@changesets/types': 6.0.0 1514 | '@manypkg/get-packages': 1.1.3 1515 | fs-extra: 7.0.1 1516 | micromatch: 4.0.7 1517 | 1518 | '@changesets/errors@0.2.0': 1519 | dependencies: 1520 | extendable-error: 0.1.7 1521 | 1522 | '@changesets/get-dependents-graph@2.1.1': 1523 | dependencies: 1524 | '@changesets/types': 6.0.0 1525 | '@manypkg/get-packages': 1.1.3 1526 | chalk: 2.4.2 1527 | fs-extra: 7.0.1 1528 | semver: 7.6.3 1529 | 1530 | '@changesets/get-release-plan@4.0.3': 1531 | dependencies: 1532 | '@babel/runtime': 7.25.0 1533 | '@changesets/assemble-release-plan': 6.0.3 1534 | '@changesets/config': 3.0.2 1535 | '@changesets/pre': 2.0.0 1536 | '@changesets/read': 0.6.0 1537 | '@changesets/types': 6.0.0 1538 | '@manypkg/get-packages': 1.1.3 1539 | 1540 | '@changesets/get-version-range-type@0.4.0': {} 1541 | 1542 | '@changesets/git@3.0.0': 1543 | dependencies: 1544 | '@babel/runtime': 7.25.0 1545 | '@changesets/errors': 0.2.0 1546 | '@changesets/types': 6.0.0 1547 | '@manypkg/get-packages': 1.1.3 1548 | is-subdir: 1.2.0 1549 | micromatch: 4.0.7 1550 | spawndamnit: 2.0.0 1551 | 1552 | '@changesets/logger@0.1.0': 1553 | dependencies: 1554 | chalk: 2.4.2 1555 | 1556 | '@changesets/parse@0.4.0': 1557 | dependencies: 1558 | '@changesets/types': 6.0.0 1559 | js-yaml: 3.14.1 1560 | 1561 | '@changesets/pre@2.0.0': 1562 | dependencies: 1563 | '@babel/runtime': 7.25.0 1564 | '@changesets/errors': 0.2.0 1565 | '@changesets/types': 6.0.0 1566 | '@manypkg/get-packages': 1.1.3 1567 | fs-extra: 7.0.1 1568 | 1569 | '@changesets/read@0.6.0': 1570 | dependencies: 1571 | '@babel/runtime': 7.25.0 1572 | '@changesets/git': 3.0.0 1573 | '@changesets/logger': 0.1.0 1574 | '@changesets/parse': 0.4.0 1575 | '@changesets/types': 6.0.0 1576 | chalk: 2.4.2 1577 | fs-extra: 7.0.1 1578 | p-filter: 2.1.0 1579 | 1580 | '@changesets/should-skip-package@0.1.0': 1581 | dependencies: 1582 | '@babel/runtime': 7.25.0 1583 | '@changesets/types': 6.0.0 1584 | '@manypkg/get-packages': 1.1.3 1585 | 1586 | '@changesets/types@4.1.0': {} 1587 | 1588 | '@changesets/types@6.0.0': {} 1589 | 1590 | '@changesets/write@0.3.1': 1591 | dependencies: 1592 | '@babel/runtime': 7.25.0 1593 | '@changesets/types': 6.0.0 1594 | fs-extra: 7.0.1 1595 | human-id: 1.0.2 1596 | prettier: 2.8.8 1597 | 1598 | '@esbuild/aix-ppc64@0.21.5': 1599 | optional: true 1600 | 1601 | '@esbuild/android-arm64@0.21.5': 1602 | optional: true 1603 | 1604 | '@esbuild/android-arm@0.21.5': 1605 | optional: true 1606 | 1607 | '@esbuild/android-x64@0.21.5': 1608 | optional: true 1609 | 1610 | '@esbuild/darwin-arm64@0.21.5': 1611 | optional: true 1612 | 1613 | '@esbuild/darwin-x64@0.21.5': 1614 | optional: true 1615 | 1616 | '@esbuild/freebsd-arm64@0.21.5': 1617 | optional: true 1618 | 1619 | '@esbuild/freebsd-x64@0.21.5': 1620 | optional: true 1621 | 1622 | '@esbuild/linux-arm64@0.21.5': 1623 | optional: true 1624 | 1625 | '@esbuild/linux-arm@0.21.5': 1626 | optional: true 1627 | 1628 | '@esbuild/linux-ia32@0.21.5': 1629 | optional: true 1630 | 1631 | '@esbuild/linux-loong64@0.21.5': 1632 | optional: true 1633 | 1634 | '@esbuild/linux-mips64el@0.21.5': 1635 | optional: true 1636 | 1637 | '@esbuild/linux-ppc64@0.21.5': 1638 | optional: true 1639 | 1640 | '@esbuild/linux-riscv64@0.21.5': 1641 | optional: true 1642 | 1643 | '@esbuild/linux-s390x@0.21.5': 1644 | optional: true 1645 | 1646 | '@esbuild/linux-x64@0.21.5': 1647 | optional: true 1648 | 1649 | '@esbuild/netbsd-x64@0.21.5': 1650 | optional: true 1651 | 1652 | '@esbuild/openbsd-x64@0.21.5': 1653 | optional: true 1654 | 1655 | '@esbuild/sunos-x64@0.21.5': 1656 | optional: true 1657 | 1658 | '@esbuild/win32-arm64@0.21.5': 1659 | optional: true 1660 | 1661 | '@esbuild/win32-ia32@0.21.5': 1662 | optional: true 1663 | 1664 | '@esbuild/win32-x64@0.21.5': 1665 | optional: true 1666 | 1667 | '@isaacs/cliui@8.0.2': 1668 | dependencies: 1669 | string-width: 5.1.2 1670 | string-width-cjs: string-width@4.2.3 1671 | strip-ansi: 7.1.0 1672 | strip-ansi-cjs: strip-ansi@6.0.1 1673 | wrap-ansi: 8.1.0 1674 | wrap-ansi-cjs: wrap-ansi@7.0.0 1675 | 1676 | '@istanbuljs/schema@0.1.3': {} 1677 | 1678 | '@jridgewell/gen-mapping@0.3.5': 1679 | dependencies: 1680 | '@jridgewell/set-array': 1.2.1 1681 | '@jridgewell/sourcemap-codec': 1.5.0 1682 | '@jridgewell/trace-mapping': 0.3.25 1683 | 1684 | '@jridgewell/resolve-uri@3.1.2': {} 1685 | 1686 | '@jridgewell/set-array@1.2.1': {} 1687 | 1688 | '@jridgewell/source-map@0.3.6': 1689 | dependencies: 1690 | '@jridgewell/gen-mapping': 0.3.5 1691 | '@jridgewell/trace-mapping': 0.3.25 1692 | 1693 | '@jridgewell/sourcemap-codec@1.5.0': {} 1694 | 1695 | '@jridgewell/trace-mapping@0.3.25': 1696 | dependencies: 1697 | '@jridgewell/resolve-uri': 3.1.2 1698 | '@jridgewell/sourcemap-codec': 1.5.0 1699 | 1700 | '@manypkg/find-root@1.1.0': 1701 | dependencies: 1702 | '@babel/runtime': 7.25.0 1703 | '@types/node': 12.20.55 1704 | find-up: 4.1.0 1705 | fs-extra: 8.1.0 1706 | 1707 | '@manypkg/get-packages@1.1.3': 1708 | dependencies: 1709 | '@babel/runtime': 7.25.0 1710 | '@changesets/types': 4.1.0 1711 | '@manypkg/find-root': 1.1.0 1712 | fs-extra: 8.1.0 1713 | globby: 11.1.0 1714 | read-yaml-file: 1.1.0 1715 | 1716 | '@nodelib/fs.scandir@2.1.5': 1717 | dependencies: 1718 | '@nodelib/fs.stat': 2.0.5 1719 | run-parallel: 1.2.0 1720 | 1721 | '@nodelib/fs.stat@2.0.5': {} 1722 | 1723 | '@nodelib/fs.walk@1.2.8': 1724 | dependencies: 1725 | '@nodelib/fs.scandir': 2.1.5 1726 | fastq: 1.17.1 1727 | 1728 | '@pkgjs/parseargs@0.11.0': 1729 | optional: true 1730 | 1731 | '@rollup/rollup-android-arm-eabi@4.18.1': 1732 | optional: true 1733 | 1734 | '@rollup/rollup-android-arm64@4.18.1': 1735 | optional: true 1736 | 1737 | '@rollup/rollup-darwin-arm64@4.18.1': 1738 | optional: true 1739 | 1740 | '@rollup/rollup-darwin-x64@4.18.1': 1741 | optional: true 1742 | 1743 | '@rollup/rollup-linux-arm-gnueabihf@4.18.1': 1744 | optional: true 1745 | 1746 | '@rollup/rollup-linux-arm-musleabihf@4.18.1': 1747 | optional: true 1748 | 1749 | '@rollup/rollup-linux-arm64-gnu@4.18.1': 1750 | optional: true 1751 | 1752 | '@rollup/rollup-linux-arm64-musl@4.18.1': 1753 | optional: true 1754 | 1755 | '@rollup/rollup-linux-powerpc64le-gnu@4.18.1': 1756 | optional: true 1757 | 1758 | '@rollup/rollup-linux-riscv64-gnu@4.18.1': 1759 | optional: true 1760 | 1761 | '@rollup/rollup-linux-s390x-gnu@4.18.1': 1762 | optional: true 1763 | 1764 | '@rollup/rollup-linux-x64-gnu@4.18.1': 1765 | optional: true 1766 | 1767 | '@rollup/rollup-linux-x64-musl@4.18.1': 1768 | optional: true 1769 | 1770 | '@rollup/rollup-win32-arm64-msvc@4.18.1': 1771 | optional: true 1772 | 1773 | '@rollup/rollup-win32-ia32-msvc@4.18.1': 1774 | optional: true 1775 | 1776 | '@rollup/rollup-win32-x64-msvc@4.18.1': 1777 | optional: true 1778 | 1779 | '@swc/core-darwin-arm64@1.6.13': 1780 | optional: true 1781 | 1782 | '@swc/core-darwin-x64@1.6.13': 1783 | optional: true 1784 | 1785 | '@swc/core-linux-arm-gnueabihf@1.6.13': 1786 | optional: true 1787 | 1788 | '@swc/core-linux-arm64-gnu@1.6.13': 1789 | optional: true 1790 | 1791 | '@swc/core-linux-arm64-musl@1.6.13': 1792 | optional: true 1793 | 1794 | '@swc/core-linux-x64-gnu@1.6.13': 1795 | optional: true 1796 | 1797 | '@swc/core-linux-x64-musl@1.6.13': 1798 | optional: true 1799 | 1800 | '@swc/core-win32-arm64-msvc@1.6.13': 1801 | optional: true 1802 | 1803 | '@swc/core-win32-ia32-msvc@1.6.13': 1804 | optional: true 1805 | 1806 | '@swc/core-win32-x64-msvc@1.6.13': 1807 | optional: true 1808 | 1809 | '@swc/core@1.6.13': 1810 | dependencies: 1811 | '@swc/counter': 0.1.3 1812 | '@swc/types': 0.1.9 1813 | optionalDependencies: 1814 | '@swc/core-darwin-arm64': 1.6.13 1815 | '@swc/core-darwin-x64': 1.6.13 1816 | '@swc/core-linux-arm-gnueabihf': 1.6.13 1817 | '@swc/core-linux-arm64-gnu': 1.6.13 1818 | '@swc/core-linux-arm64-musl': 1.6.13 1819 | '@swc/core-linux-x64-gnu': 1.6.13 1820 | '@swc/core-linux-x64-musl': 1.6.13 1821 | '@swc/core-win32-arm64-msvc': 1.6.13 1822 | '@swc/core-win32-ia32-msvc': 1.6.13 1823 | '@swc/core-win32-x64-msvc': 1.6.13 1824 | 1825 | '@swc/counter@0.1.3': {} 1826 | 1827 | '@swc/types@0.1.9': 1828 | dependencies: 1829 | '@swc/counter': 0.1.3 1830 | 1831 | '@types/estree@1.0.5': {} 1832 | 1833 | '@types/node@12.20.55': {} 1834 | 1835 | '@types/node@20.14.10': 1836 | dependencies: 1837 | undici-types: 5.26.5 1838 | 1839 | '@types/semver@7.5.8': {} 1840 | 1841 | '@vitest/coverage-v8@2.0.5(vitest@2.0.5(@types/node@20.14.10)(terser@5.31.2))': 1842 | dependencies: 1843 | '@ampproject/remapping': 2.3.0 1844 | '@bcoe/v8-coverage': 0.2.3 1845 | debug: 4.3.5 1846 | istanbul-lib-coverage: 3.2.2 1847 | istanbul-lib-report: 3.0.1 1848 | istanbul-lib-source-maps: 5.0.6 1849 | istanbul-reports: 3.1.7 1850 | magic-string: 0.30.10 1851 | magicast: 0.3.4 1852 | std-env: 3.7.0 1853 | test-exclude: 7.0.1 1854 | tinyrainbow: 1.2.0 1855 | vitest: 2.0.5(@types/node@20.14.10)(terser@5.31.2) 1856 | transitivePeerDependencies: 1857 | - supports-color 1858 | 1859 | '@vitest/expect@2.0.5': 1860 | dependencies: 1861 | '@vitest/spy': 2.0.5 1862 | '@vitest/utils': 2.0.5 1863 | chai: 5.1.1 1864 | tinyrainbow: 1.2.0 1865 | 1866 | '@vitest/pretty-format@2.0.5': 1867 | dependencies: 1868 | tinyrainbow: 1.2.0 1869 | 1870 | '@vitest/runner@2.0.5': 1871 | dependencies: 1872 | '@vitest/utils': 2.0.5 1873 | pathe: 1.1.2 1874 | 1875 | '@vitest/snapshot@2.0.5': 1876 | dependencies: 1877 | '@vitest/pretty-format': 2.0.5 1878 | magic-string: 0.30.10 1879 | pathe: 1.1.2 1880 | 1881 | '@vitest/spy@2.0.5': 1882 | dependencies: 1883 | tinyspy: 3.0.0 1884 | 1885 | '@vitest/utils@2.0.5': 1886 | dependencies: 1887 | '@vitest/pretty-format': 2.0.5 1888 | estree-walker: 3.0.3 1889 | loupe: 3.1.1 1890 | tinyrainbow: 1.2.0 1891 | 1892 | acorn@8.12.1: {} 1893 | 1894 | ansi-colors@4.1.3: {} 1895 | 1896 | ansi-regex@5.0.1: {} 1897 | 1898 | ansi-regex@6.0.1: {} 1899 | 1900 | ansi-styles@3.2.1: 1901 | dependencies: 1902 | color-convert: 1.9.3 1903 | 1904 | ansi-styles@4.3.0: 1905 | dependencies: 1906 | color-convert: 2.0.1 1907 | 1908 | ansi-styles@6.2.1: {} 1909 | 1910 | any-promise@1.3.0: {} 1911 | 1912 | anymatch@3.1.3: 1913 | dependencies: 1914 | normalize-path: 3.0.0 1915 | picomatch: 2.3.1 1916 | 1917 | argparse@1.0.10: 1918 | dependencies: 1919 | sprintf-js: 1.0.3 1920 | 1921 | array-union@2.1.0: {} 1922 | 1923 | assertion-error@2.0.1: {} 1924 | 1925 | balanced-match@1.0.2: {} 1926 | 1927 | better-path-resolve@1.0.0: 1928 | dependencies: 1929 | is-windows: 1.0.2 1930 | 1931 | binary-extensions@2.3.0: {} 1932 | 1933 | brace-expansion@2.0.1: 1934 | dependencies: 1935 | balanced-match: 1.0.2 1936 | 1937 | braces@3.0.3: 1938 | dependencies: 1939 | fill-range: 7.1.1 1940 | 1941 | buffer-from@1.1.2: {} 1942 | 1943 | bundle-require@4.2.1(esbuild@0.21.5): 1944 | dependencies: 1945 | esbuild: 0.21.5 1946 | load-tsconfig: 0.2.5 1947 | 1948 | cac@6.7.14: {} 1949 | 1950 | chai@5.1.1: 1951 | dependencies: 1952 | assertion-error: 2.0.1 1953 | check-error: 2.1.1 1954 | deep-eql: 5.0.2 1955 | loupe: 3.1.1 1956 | pathval: 2.0.0 1957 | 1958 | chalk@2.4.2: 1959 | dependencies: 1960 | ansi-styles: 3.2.1 1961 | escape-string-regexp: 1.0.5 1962 | supports-color: 5.5.0 1963 | 1964 | chardet@0.7.0: {} 1965 | 1966 | check-error@2.1.1: {} 1967 | 1968 | chokidar@3.6.0: 1969 | dependencies: 1970 | anymatch: 3.1.3 1971 | braces: 3.0.3 1972 | glob-parent: 5.1.2 1973 | is-binary-path: 2.1.0 1974 | is-glob: 4.0.3 1975 | normalize-path: 3.0.0 1976 | readdirp: 3.6.0 1977 | optionalDependencies: 1978 | fsevents: 2.3.3 1979 | 1980 | ci-info@3.9.0: {} 1981 | 1982 | color-convert@1.9.3: 1983 | dependencies: 1984 | color-name: 1.1.3 1985 | 1986 | color-convert@2.0.1: 1987 | dependencies: 1988 | color-name: 1.1.4 1989 | 1990 | color-name@1.1.3: {} 1991 | 1992 | color-name@1.1.4: {} 1993 | 1994 | commander@2.20.3: {} 1995 | 1996 | commander@4.1.1: {} 1997 | 1998 | cross-spawn@5.1.0: 1999 | dependencies: 2000 | lru-cache: 4.1.5 2001 | shebang-command: 1.2.0 2002 | which: 1.3.1 2003 | 2004 | cross-spawn@7.0.3: 2005 | dependencies: 2006 | path-key: 3.1.1 2007 | shebang-command: 2.0.0 2008 | which: 2.0.2 2009 | 2010 | debug@4.3.5: 2011 | dependencies: 2012 | ms: 2.1.2 2013 | 2014 | deep-eql@5.0.2: {} 2015 | 2016 | detect-indent@6.1.0: {} 2017 | 2018 | dir-glob@3.0.1: 2019 | dependencies: 2020 | path-type: 4.0.0 2021 | 2022 | eastasianwidth@0.2.0: {} 2023 | 2024 | emoji-regex@8.0.0: {} 2025 | 2026 | emoji-regex@9.2.2: {} 2027 | 2028 | enquirer@2.4.1: 2029 | dependencies: 2030 | ansi-colors: 4.1.3 2031 | strip-ansi: 6.0.1 2032 | 2033 | esbuild@0.21.5: 2034 | optionalDependencies: 2035 | '@esbuild/aix-ppc64': 0.21.5 2036 | '@esbuild/android-arm': 0.21.5 2037 | '@esbuild/android-arm64': 0.21.5 2038 | '@esbuild/android-x64': 0.21.5 2039 | '@esbuild/darwin-arm64': 0.21.5 2040 | '@esbuild/darwin-x64': 0.21.5 2041 | '@esbuild/freebsd-arm64': 0.21.5 2042 | '@esbuild/freebsd-x64': 0.21.5 2043 | '@esbuild/linux-arm': 0.21.5 2044 | '@esbuild/linux-arm64': 0.21.5 2045 | '@esbuild/linux-ia32': 0.21.5 2046 | '@esbuild/linux-loong64': 0.21.5 2047 | '@esbuild/linux-mips64el': 0.21.5 2048 | '@esbuild/linux-ppc64': 0.21.5 2049 | '@esbuild/linux-riscv64': 0.21.5 2050 | '@esbuild/linux-s390x': 0.21.5 2051 | '@esbuild/linux-x64': 0.21.5 2052 | '@esbuild/netbsd-x64': 0.21.5 2053 | '@esbuild/openbsd-x64': 0.21.5 2054 | '@esbuild/sunos-x64': 0.21.5 2055 | '@esbuild/win32-arm64': 0.21.5 2056 | '@esbuild/win32-ia32': 0.21.5 2057 | '@esbuild/win32-x64': 0.21.5 2058 | 2059 | escape-string-regexp@1.0.5: {} 2060 | 2061 | esprima@4.0.1: {} 2062 | 2063 | estree-walker@3.0.3: 2064 | dependencies: 2065 | '@types/estree': 1.0.5 2066 | 2067 | execa@5.1.1: 2068 | dependencies: 2069 | cross-spawn: 7.0.3 2070 | get-stream: 6.0.1 2071 | human-signals: 2.1.0 2072 | is-stream: 2.0.1 2073 | merge-stream: 2.0.0 2074 | npm-run-path: 4.0.1 2075 | onetime: 5.1.2 2076 | signal-exit: 3.0.7 2077 | strip-final-newline: 2.0.0 2078 | 2079 | execa@8.0.1: 2080 | dependencies: 2081 | cross-spawn: 7.0.3 2082 | get-stream: 8.0.1 2083 | human-signals: 5.0.0 2084 | is-stream: 3.0.0 2085 | merge-stream: 2.0.0 2086 | npm-run-path: 5.3.0 2087 | onetime: 6.0.0 2088 | signal-exit: 4.1.0 2089 | strip-final-newline: 3.0.0 2090 | 2091 | extendable-error@0.1.7: {} 2092 | 2093 | external-editor@3.1.0: 2094 | dependencies: 2095 | chardet: 0.7.0 2096 | iconv-lite: 0.4.24 2097 | tmp: 0.0.33 2098 | 2099 | fast-glob@3.3.2: 2100 | dependencies: 2101 | '@nodelib/fs.stat': 2.0.5 2102 | '@nodelib/fs.walk': 1.2.8 2103 | glob-parent: 5.1.2 2104 | merge2: 1.4.1 2105 | micromatch: 4.0.7 2106 | 2107 | fastq@1.17.1: 2108 | dependencies: 2109 | reusify: 1.0.4 2110 | 2111 | fill-range@7.1.1: 2112 | dependencies: 2113 | to-regex-range: 5.0.1 2114 | 2115 | find-up@4.1.0: 2116 | dependencies: 2117 | locate-path: 5.0.0 2118 | path-exists: 4.0.0 2119 | 2120 | find-up@5.0.0: 2121 | dependencies: 2122 | locate-path: 6.0.0 2123 | path-exists: 4.0.0 2124 | 2125 | find-yarn-workspace-root2@1.2.16: 2126 | dependencies: 2127 | micromatch: 4.0.7 2128 | pkg-dir: 4.2.0 2129 | 2130 | foreground-child@3.2.1: 2131 | dependencies: 2132 | cross-spawn: 7.0.3 2133 | signal-exit: 4.1.0 2134 | 2135 | fs-extra@7.0.1: 2136 | dependencies: 2137 | graceful-fs: 4.2.11 2138 | jsonfile: 4.0.0 2139 | universalify: 0.1.2 2140 | 2141 | fs-extra@8.1.0: 2142 | dependencies: 2143 | graceful-fs: 4.2.11 2144 | jsonfile: 4.0.0 2145 | universalify: 0.1.2 2146 | 2147 | fsevents@2.3.3: 2148 | optional: true 2149 | 2150 | get-func-name@2.0.2: {} 2151 | 2152 | get-stream@6.0.1: {} 2153 | 2154 | get-stream@8.0.1: {} 2155 | 2156 | glob-parent@5.1.2: 2157 | dependencies: 2158 | is-glob: 4.0.3 2159 | 2160 | glob@10.4.5: 2161 | dependencies: 2162 | foreground-child: 3.2.1 2163 | jackspeak: 3.4.2 2164 | minimatch: 9.0.5 2165 | minipass: 7.1.2 2166 | package-json-from-dist: 1.0.0 2167 | path-scurry: 1.11.1 2168 | 2169 | globby@11.1.0: 2170 | dependencies: 2171 | array-union: 2.1.0 2172 | dir-glob: 3.0.1 2173 | fast-glob: 3.3.2 2174 | ignore: 5.3.1 2175 | merge2: 1.4.1 2176 | slash: 3.0.0 2177 | 2178 | graceful-fs@4.2.11: {} 2179 | 2180 | has-flag@3.0.0: {} 2181 | 2182 | has-flag@4.0.0: {} 2183 | 2184 | html-escaper@2.0.2: {} 2185 | 2186 | human-id@1.0.2: {} 2187 | 2188 | human-signals@2.1.0: {} 2189 | 2190 | human-signals@5.0.0: {} 2191 | 2192 | iconv-lite@0.4.24: 2193 | dependencies: 2194 | safer-buffer: 2.1.2 2195 | 2196 | ignore@5.3.1: {} 2197 | 2198 | is-binary-path@2.1.0: 2199 | dependencies: 2200 | binary-extensions: 2.3.0 2201 | 2202 | is-extglob@2.1.1: {} 2203 | 2204 | is-fullwidth-code-point@3.0.0: {} 2205 | 2206 | is-glob@4.0.3: 2207 | dependencies: 2208 | is-extglob: 2.1.1 2209 | 2210 | is-number@7.0.0: {} 2211 | 2212 | is-stream@2.0.1: {} 2213 | 2214 | is-stream@3.0.0: {} 2215 | 2216 | is-subdir@1.2.0: 2217 | dependencies: 2218 | better-path-resolve: 1.0.0 2219 | 2220 | is-windows@1.0.2: {} 2221 | 2222 | isexe@2.0.0: {} 2223 | 2224 | istanbul-lib-coverage@3.2.2: {} 2225 | 2226 | istanbul-lib-report@3.0.1: 2227 | dependencies: 2228 | istanbul-lib-coverage: 3.2.2 2229 | make-dir: 4.0.0 2230 | supports-color: 7.2.0 2231 | 2232 | istanbul-lib-source-maps@5.0.6: 2233 | dependencies: 2234 | '@jridgewell/trace-mapping': 0.3.25 2235 | debug: 4.3.5 2236 | istanbul-lib-coverage: 3.2.2 2237 | transitivePeerDependencies: 2238 | - supports-color 2239 | 2240 | istanbul-reports@3.1.7: 2241 | dependencies: 2242 | html-escaper: 2.0.2 2243 | istanbul-lib-report: 3.0.1 2244 | 2245 | jackspeak@3.4.2: 2246 | dependencies: 2247 | '@isaacs/cliui': 8.0.2 2248 | optionalDependencies: 2249 | '@pkgjs/parseargs': 0.11.0 2250 | 2251 | joycon@3.1.1: {} 2252 | 2253 | js-yaml@3.14.1: 2254 | dependencies: 2255 | argparse: 1.0.10 2256 | esprima: 4.0.1 2257 | 2258 | jsonfile@4.0.0: 2259 | optionalDependencies: 2260 | graceful-fs: 4.2.11 2261 | 2262 | lilconfig@3.1.2: {} 2263 | 2264 | lines-and-columns@1.2.4: {} 2265 | 2266 | load-tsconfig@0.2.5: {} 2267 | 2268 | load-yaml-file@0.2.0: 2269 | dependencies: 2270 | graceful-fs: 4.2.11 2271 | js-yaml: 3.14.1 2272 | pify: 4.0.1 2273 | strip-bom: 3.0.0 2274 | 2275 | locate-path@5.0.0: 2276 | dependencies: 2277 | p-locate: 4.1.0 2278 | 2279 | locate-path@6.0.0: 2280 | dependencies: 2281 | p-locate: 5.0.0 2282 | 2283 | lodash.sortby@4.7.0: {} 2284 | 2285 | lodash.startcase@4.4.0: {} 2286 | 2287 | loupe@3.1.1: 2288 | dependencies: 2289 | get-func-name: 2.0.2 2290 | 2291 | lru-cache@10.4.3: {} 2292 | 2293 | lru-cache@4.1.5: 2294 | dependencies: 2295 | pseudomap: 1.0.2 2296 | yallist: 2.1.2 2297 | 2298 | magic-string@0.30.10: 2299 | dependencies: 2300 | '@jridgewell/sourcemap-codec': 1.5.0 2301 | 2302 | magicast@0.3.4: 2303 | dependencies: 2304 | '@babel/parser': 7.25.3 2305 | '@babel/types': 7.25.2 2306 | source-map-js: 1.2.0 2307 | 2308 | make-dir@4.0.0: 2309 | dependencies: 2310 | semver: 7.6.3 2311 | 2312 | merge-stream@2.0.0: {} 2313 | 2314 | merge2@1.4.1: {} 2315 | 2316 | micromatch@4.0.7: 2317 | dependencies: 2318 | braces: 3.0.3 2319 | picomatch: 2.3.1 2320 | 2321 | mimic-fn@2.1.0: {} 2322 | 2323 | mimic-fn@4.0.0: {} 2324 | 2325 | minimatch@9.0.5: 2326 | dependencies: 2327 | brace-expansion: 2.0.1 2328 | 2329 | minipass@7.1.2: {} 2330 | 2331 | mri@1.2.0: {} 2332 | 2333 | ms@2.1.2: {} 2334 | 2335 | mz@2.7.0: 2336 | dependencies: 2337 | any-promise: 1.3.0 2338 | object-assign: 4.1.1 2339 | thenify-all: 1.6.0 2340 | 2341 | nanoid@3.3.7: {} 2342 | 2343 | normalize-path@3.0.0: {} 2344 | 2345 | npm-run-path@4.0.1: 2346 | dependencies: 2347 | path-key: 3.1.1 2348 | 2349 | npm-run-path@5.3.0: 2350 | dependencies: 2351 | path-key: 4.0.0 2352 | 2353 | object-assign@4.1.1: {} 2354 | 2355 | onetime@5.1.2: 2356 | dependencies: 2357 | mimic-fn: 2.1.0 2358 | 2359 | onetime@6.0.0: 2360 | dependencies: 2361 | mimic-fn: 4.0.0 2362 | 2363 | os-tmpdir@1.0.2: {} 2364 | 2365 | outdent@0.5.0: {} 2366 | 2367 | p-filter@2.1.0: 2368 | dependencies: 2369 | p-map: 2.1.0 2370 | 2371 | p-limit@2.3.0: 2372 | dependencies: 2373 | p-try: 2.2.0 2374 | 2375 | p-limit@3.1.0: 2376 | dependencies: 2377 | yocto-queue: 0.1.0 2378 | 2379 | p-locate@4.1.0: 2380 | dependencies: 2381 | p-limit: 2.3.0 2382 | 2383 | p-locate@5.0.0: 2384 | dependencies: 2385 | p-limit: 3.1.0 2386 | 2387 | p-map@2.1.0: {} 2388 | 2389 | p-try@2.2.0: {} 2390 | 2391 | package-json-from-dist@1.0.0: {} 2392 | 2393 | path-exists@4.0.0: {} 2394 | 2395 | path-key@3.1.1: {} 2396 | 2397 | path-key@4.0.0: {} 2398 | 2399 | path-scurry@1.11.1: 2400 | dependencies: 2401 | lru-cache: 10.4.3 2402 | minipass: 7.1.2 2403 | 2404 | path-type@4.0.0: {} 2405 | 2406 | pathe@1.1.2: {} 2407 | 2408 | pathval@2.0.0: {} 2409 | 2410 | picocolors@1.0.1: {} 2411 | 2412 | picomatch@2.3.1: {} 2413 | 2414 | pify@4.0.1: {} 2415 | 2416 | pirates@4.0.6: {} 2417 | 2418 | pkg-dir@4.2.0: 2419 | dependencies: 2420 | find-up: 4.1.0 2421 | 2422 | postcss-load-config@4.0.2(postcss@8.4.39): 2423 | dependencies: 2424 | lilconfig: 3.1.2 2425 | yaml: 2.4.5 2426 | optionalDependencies: 2427 | postcss: 8.4.39 2428 | 2429 | postcss@8.4.39: 2430 | dependencies: 2431 | nanoid: 3.3.7 2432 | picocolors: 1.0.1 2433 | source-map-js: 1.2.0 2434 | 2435 | preferred-pm@3.1.4: 2436 | dependencies: 2437 | find-up: 5.0.0 2438 | find-yarn-workspace-root2: 1.2.16 2439 | path-exists: 4.0.0 2440 | which-pm: 2.2.0 2441 | 2442 | prettier@2.8.8: {} 2443 | 2444 | pseudomap@1.0.2: {} 2445 | 2446 | punycode@2.3.1: {} 2447 | 2448 | queue-microtask@1.2.3: {} 2449 | 2450 | read-yaml-file@1.1.0: 2451 | dependencies: 2452 | graceful-fs: 4.2.11 2453 | js-yaml: 3.14.1 2454 | pify: 4.0.1 2455 | strip-bom: 3.0.0 2456 | 2457 | readdirp@3.6.0: 2458 | dependencies: 2459 | picomatch: 2.3.1 2460 | 2461 | regenerator-runtime@0.14.1: {} 2462 | 2463 | resolve-from@5.0.0: {} 2464 | 2465 | reusify@1.0.4: {} 2466 | 2467 | rollup@4.18.1: 2468 | dependencies: 2469 | '@types/estree': 1.0.5 2470 | optionalDependencies: 2471 | '@rollup/rollup-android-arm-eabi': 4.18.1 2472 | '@rollup/rollup-android-arm64': 4.18.1 2473 | '@rollup/rollup-darwin-arm64': 4.18.1 2474 | '@rollup/rollup-darwin-x64': 4.18.1 2475 | '@rollup/rollup-linux-arm-gnueabihf': 4.18.1 2476 | '@rollup/rollup-linux-arm-musleabihf': 4.18.1 2477 | '@rollup/rollup-linux-arm64-gnu': 4.18.1 2478 | '@rollup/rollup-linux-arm64-musl': 4.18.1 2479 | '@rollup/rollup-linux-powerpc64le-gnu': 4.18.1 2480 | '@rollup/rollup-linux-riscv64-gnu': 4.18.1 2481 | '@rollup/rollup-linux-s390x-gnu': 4.18.1 2482 | '@rollup/rollup-linux-x64-gnu': 4.18.1 2483 | '@rollup/rollup-linux-x64-musl': 4.18.1 2484 | '@rollup/rollup-win32-arm64-msvc': 4.18.1 2485 | '@rollup/rollup-win32-ia32-msvc': 4.18.1 2486 | '@rollup/rollup-win32-x64-msvc': 4.18.1 2487 | fsevents: 2.3.3 2488 | 2489 | run-parallel@1.2.0: 2490 | dependencies: 2491 | queue-microtask: 1.2.3 2492 | 2493 | safer-buffer@2.1.2: {} 2494 | 2495 | semver@7.6.3: {} 2496 | 2497 | shebang-command@1.2.0: 2498 | dependencies: 2499 | shebang-regex: 1.0.0 2500 | 2501 | shebang-command@2.0.0: 2502 | dependencies: 2503 | shebang-regex: 3.0.0 2504 | 2505 | shebang-regex@1.0.0: {} 2506 | 2507 | shebang-regex@3.0.0: {} 2508 | 2509 | siginfo@2.0.0: {} 2510 | 2511 | signal-exit@3.0.7: {} 2512 | 2513 | signal-exit@4.1.0: {} 2514 | 2515 | slash@3.0.0: {} 2516 | 2517 | source-map-js@1.2.0: {} 2518 | 2519 | source-map-support@0.5.21: 2520 | dependencies: 2521 | buffer-from: 1.1.2 2522 | source-map: 0.6.1 2523 | 2524 | source-map@0.6.1: {} 2525 | 2526 | source-map@0.8.0-beta.0: 2527 | dependencies: 2528 | whatwg-url: 7.1.0 2529 | 2530 | spawndamnit@2.0.0: 2531 | dependencies: 2532 | cross-spawn: 5.1.0 2533 | signal-exit: 3.0.7 2534 | 2535 | sprintf-js@1.0.3: {} 2536 | 2537 | stackback@0.0.2: {} 2538 | 2539 | std-env@3.7.0: {} 2540 | 2541 | string-width@4.2.3: 2542 | dependencies: 2543 | emoji-regex: 8.0.0 2544 | is-fullwidth-code-point: 3.0.0 2545 | strip-ansi: 6.0.1 2546 | 2547 | string-width@5.1.2: 2548 | dependencies: 2549 | eastasianwidth: 0.2.0 2550 | emoji-regex: 9.2.2 2551 | strip-ansi: 7.1.0 2552 | 2553 | strip-ansi@6.0.1: 2554 | dependencies: 2555 | ansi-regex: 5.0.1 2556 | 2557 | strip-ansi@7.1.0: 2558 | dependencies: 2559 | ansi-regex: 6.0.1 2560 | 2561 | strip-bom@3.0.0: {} 2562 | 2563 | strip-final-newline@2.0.0: {} 2564 | 2565 | strip-final-newline@3.0.0: {} 2566 | 2567 | sucrase@3.35.0: 2568 | dependencies: 2569 | '@jridgewell/gen-mapping': 0.3.5 2570 | commander: 4.1.1 2571 | glob: 10.4.5 2572 | lines-and-columns: 1.2.4 2573 | mz: 2.7.0 2574 | pirates: 4.0.6 2575 | ts-interface-checker: 0.1.13 2576 | 2577 | supports-color@5.5.0: 2578 | dependencies: 2579 | has-flag: 3.0.0 2580 | 2581 | supports-color@7.2.0: 2582 | dependencies: 2583 | has-flag: 4.0.0 2584 | 2585 | term-size@2.2.1: {} 2586 | 2587 | terser@5.31.2: 2588 | dependencies: 2589 | '@jridgewell/source-map': 0.3.6 2590 | acorn: 8.12.1 2591 | commander: 2.20.3 2592 | source-map-support: 0.5.21 2593 | 2594 | test-exclude@7.0.1: 2595 | dependencies: 2596 | '@istanbuljs/schema': 0.1.3 2597 | glob: 10.4.5 2598 | minimatch: 9.0.5 2599 | 2600 | thenify-all@1.6.0: 2601 | dependencies: 2602 | thenify: 3.3.1 2603 | 2604 | thenify@3.3.1: 2605 | dependencies: 2606 | any-promise: 1.3.0 2607 | 2608 | tinybench@2.8.0: {} 2609 | 2610 | tinypool@1.0.0: {} 2611 | 2612 | tinyrainbow@1.2.0: {} 2613 | 2614 | tinyspy@3.0.0: {} 2615 | 2616 | tmp@0.0.33: 2617 | dependencies: 2618 | os-tmpdir: 1.0.2 2619 | 2620 | to-fast-properties@2.0.0: {} 2621 | 2622 | to-regex-range@5.0.1: 2623 | dependencies: 2624 | is-number: 7.0.0 2625 | 2626 | tr46@1.0.1: 2627 | dependencies: 2628 | punycode: 2.3.1 2629 | 2630 | tree-kill@1.2.2: {} 2631 | 2632 | ts-interface-checker@0.1.13: {} 2633 | 2634 | tsup@8.1.0(@swc/core@1.6.13)(postcss@8.4.39)(typescript@5.5.3): 2635 | dependencies: 2636 | bundle-require: 4.2.1(esbuild@0.21.5) 2637 | cac: 6.7.14 2638 | chokidar: 3.6.0 2639 | debug: 4.3.5 2640 | esbuild: 0.21.5 2641 | execa: 5.1.1 2642 | globby: 11.1.0 2643 | joycon: 3.1.1 2644 | postcss-load-config: 4.0.2(postcss@8.4.39) 2645 | resolve-from: 5.0.0 2646 | rollup: 4.18.1 2647 | source-map: 0.8.0-beta.0 2648 | sucrase: 3.35.0 2649 | tree-kill: 1.2.2 2650 | optionalDependencies: 2651 | '@swc/core': 1.6.13 2652 | postcss: 8.4.39 2653 | typescript: 5.5.3 2654 | transitivePeerDependencies: 2655 | - supports-color 2656 | - ts-node 2657 | 2658 | typescript@5.5.3: {} 2659 | 2660 | undici-types@5.26.5: {} 2661 | 2662 | universalify@0.1.2: {} 2663 | 2664 | vite-node@2.0.5(@types/node@20.14.10)(terser@5.31.2): 2665 | dependencies: 2666 | cac: 6.7.14 2667 | debug: 4.3.5 2668 | pathe: 1.1.2 2669 | tinyrainbow: 1.2.0 2670 | vite: 5.3.3(@types/node@20.14.10)(terser@5.31.2) 2671 | transitivePeerDependencies: 2672 | - '@types/node' 2673 | - less 2674 | - lightningcss 2675 | - sass 2676 | - stylus 2677 | - sugarss 2678 | - supports-color 2679 | - terser 2680 | 2681 | vite@5.3.3(@types/node@20.14.10)(terser@5.31.2): 2682 | dependencies: 2683 | esbuild: 0.21.5 2684 | postcss: 8.4.39 2685 | rollup: 4.18.1 2686 | optionalDependencies: 2687 | '@types/node': 20.14.10 2688 | fsevents: 2.3.3 2689 | terser: 5.31.2 2690 | 2691 | vitest@2.0.5(@types/node@20.14.10)(terser@5.31.2): 2692 | dependencies: 2693 | '@ampproject/remapping': 2.3.0 2694 | '@vitest/expect': 2.0.5 2695 | '@vitest/pretty-format': 2.0.5 2696 | '@vitest/runner': 2.0.5 2697 | '@vitest/snapshot': 2.0.5 2698 | '@vitest/spy': 2.0.5 2699 | '@vitest/utils': 2.0.5 2700 | chai: 5.1.1 2701 | debug: 4.3.5 2702 | execa: 8.0.1 2703 | magic-string: 0.30.10 2704 | pathe: 1.1.2 2705 | std-env: 3.7.0 2706 | tinybench: 2.8.0 2707 | tinypool: 1.0.0 2708 | tinyrainbow: 1.2.0 2709 | vite: 5.3.3(@types/node@20.14.10)(terser@5.31.2) 2710 | vite-node: 2.0.5(@types/node@20.14.10)(terser@5.31.2) 2711 | why-is-node-running: 2.3.0 2712 | optionalDependencies: 2713 | '@types/node': 20.14.10 2714 | transitivePeerDependencies: 2715 | - less 2716 | - lightningcss 2717 | - sass 2718 | - stylus 2719 | - sugarss 2720 | - supports-color 2721 | - terser 2722 | 2723 | webidl-conversions@4.0.2: {} 2724 | 2725 | whatwg-url@7.1.0: 2726 | dependencies: 2727 | lodash.sortby: 4.7.0 2728 | tr46: 1.0.1 2729 | webidl-conversions: 4.0.2 2730 | 2731 | which-pm@2.2.0: 2732 | dependencies: 2733 | load-yaml-file: 0.2.0 2734 | path-exists: 4.0.0 2735 | 2736 | which@1.3.1: 2737 | dependencies: 2738 | isexe: 2.0.0 2739 | 2740 | which@2.0.2: 2741 | dependencies: 2742 | isexe: 2.0.0 2743 | 2744 | why-is-node-running@2.3.0: 2745 | dependencies: 2746 | siginfo: 2.0.0 2747 | stackback: 0.0.2 2748 | 2749 | wrap-ansi@7.0.0: 2750 | dependencies: 2751 | ansi-styles: 4.3.0 2752 | string-width: 4.2.3 2753 | strip-ansi: 6.0.1 2754 | 2755 | wrap-ansi@8.1.0: 2756 | dependencies: 2757 | ansi-styles: 6.2.1 2758 | string-width: 5.1.2 2759 | strip-ansi: 7.1.0 2760 | 2761 | yallist@2.1.2: {} 2762 | 2763 | yaml@2.4.5: {} 2764 | 2765 | yocto-queue@0.1.0: {} 2766 | --------------------------------------------------------------------------------