├── .gitattributes ├── .github └── workflows │ └── main.yml ├── .gitignore ├── LICENSE ├── README.md ├── dist ├── index.cjs ├── index.d.cts ├── index.d.mts └── index.mjs ├── package-lock.json ├── package.json ├── setupVitest.ts ├── src ├── index.test.ts └── index.ts ├── tsconfig.json └── vitest.config.ts /.gitattributes: -------------------------------------------------------------------------------- 1 | # based on Sindre Sorhus `node-module-boilerplate`: 2 | # https://github.com/sindresorhus/node-module-boilerplate/blob/9b8dc81a35acfbd3b75f7f19c9679e4f83b36df3/.gitattributes 3 | * text=auto eol=lf 4 | -------------------------------------------------------------------------------- /.github/workflows/main.yml: -------------------------------------------------------------------------------- 1 | name: CI 2 | on: 3 | - push 4 | - pull_request 5 | jobs: 6 | test: 7 | name: Node.js ${{ matrix.node-version }} 8 | runs-on: ubuntu-latest 9 | strategy: 10 | # `fail-fast` is set to `false` because we won't know which Node versions are failing and which are passing 11 | fail-fast: false 12 | matrix: 13 | node-version: 14 | - 18 15 | - 16 16 | - 14 17 | - 12 18 | steps: 19 | - uses: actions/checkout@v3 20 | - uses: actions/setup-node@v3 21 | with: 22 | node-version: ${{ matrix.node-version }} 23 | - run: yarn install 24 | - run: yarn test 25 | -------------------------------------------------------------------------------- /.gitignore: -------------------------------------------------------------------------------- 1 | /node_modules 2 | 3 | .attest 4 | *.js 5 | yarn.lock 6 | yarn-error.log 7 | .eslintcache 8 | -------------------------------------------------------------------------------- /LICENSE: -------------------------------------------------------------------------------- 1 | MIT License 2 | 3 | Copyright (c) 2025 Alisson Cavalcante Agiani thelinuxlich@gmail.com 4 | Copyright (c) 2022 Antonio Stoilkov hello@astoilkov.com https://astoilkov.com 5 | 6 | Permission is hereby granted, free of charge, to any person obtaining a copy 7 | of this software and associated documentation files (the "Software"), to deal 8 | in the Software without restriction, including without limitation the rights 9 | to use, copy, modify, merge, publish, distribute, sublicense, and/or sell 10 | copies of the Software, and to permit persons to whom the Software is 11 | furnished to do so, subject to the following conditions: 12 | 13 | The above copyright notice and this permission notice shall be included in all 14 | copies or substantial portions of the Software. 15 | 16 | THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR 17 | IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, 18 | FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE 19 | AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER 20 | LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, 21 | OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE 22 | SOFTWARE. 23 | -------------------------------------------------------------------------------- /README.md: -------------------------------------------------------------------------------- 1 | # `go-go-try` 2 | 3 | > Tries to execute a sync/async function, returns a Golang style result. 4 | 5 | ## Why 6 | 7 | - Supports sync/async functions. 8 | - Allows you to capture the thrown error. 9 | - Written in TypeScript. The types are written in a way that reduce developer errors. 10 | - Inspired by Golang error catching. 11 | - Zero dependencies. 12 | 13 | Why not just `try`/`catch`? 14 | 15 | - In a lot of cases, `try`/`catch` is still the better option. 16 | - Nested `try`/`catch` statements are hard to process mentally. They also indent the code and make it hard to read. A single `try`/`catch` does the same but to a lesser degree. 17 | - If you [prefer const](https://eslint.org/docs/latest/rules/prefer-const), `try`/`catch` statements get in the way because you need to use `let` if you need the variable outside of the `try`/`catch` scope: 18 | ```ts 19 | let todos 20 | try { 21 | todos = JSON.parse(localStorage.getItem('todos')) 22 | } catch {} 23 | return todos.filter((todo) => todo.done) 24 | ``` 25 | - It takes more space. It's slower to type. 26 | 27 | ## Install 28 | 29 | ```bash 30 | npm install go-go-try 31 | ``` 32 | 33 | ## Usage 34 | 35 | ```ts 36 | import { goTry, goTryRaw } from 'go-go-try' 37 | 38 | // tries to parse todos, returns empty array if it fails 39 | const [_, value = []] = goTry(() => JSON.parse(todos)) 40 | 41 | // fetch todos, on error, fallback to empty array 42 | const [_, todos = []] = await goTry(fetchTodos()) 43 | 44 | // fetch todos, fallback to empty array, send error to your error tracking service 45 | const [err, todos = []] = await goTry(fetchTodos()) // err is string | undefined 46 | if (err) sendToErrorTrackingService(err) 47 | 48 | // goTry extracts the error message from the error object, if you want the raw error object, use goTryRaw 49 | const [err, value] = goTryRaw(() => JSON.parse('{/}')) // err is Error | undefined, value is T | undefined 50 | 51 | // fetch todos, fallback to empty array, send error to your error tracking service 52 | const [err, todos = []] = await goTryRaw(fetchTodos()) // err is Error | undefined 53 | if (err) sendToErrorTrackingService(err) 54 | ``` 55 | 56 | ## API 57 | 58 | **First parameter** accepts: 59 | 60 | - synchronous/asynchronous function / Promise 61 | 62 | **Returns** a tuple with the possible error and result as `[Err | undefined, T | undefined]` (Golang style) 63 | 64 | 65 | If you use TypeScript, the types are well defined and won't let you make a mistake. 66 | -------------------------------------------------------------------------------- /dist/index.cjs: -------------------------------------------------------------------------------- 1 | 'use strict'; 2 | 3 | function isSuccess(result) { 4 | return result[0] === void 0; 5 | } 6 | function isFailure(result) { 7 | return result[0] !== void 0; 8 | } 9 | function success(value) { 10 | return [void 0, value]; 11 | } 12 | function failure(error) { 13 | return [error, void 0]; 14 | } 15 | function getErrorMessage(error) { 16 | if (error === void 0) return "undefined"; 17 | if (typeof error === "string") return error; 18 | if (typeof error === "object" && error !== null && "message" in error && typeof error.message === "string") { 19 | return error.message; 20 | } 21 | try { 22 | return JSON.stringify(error); 23 | } catch { 24 | return String(error); 25 | } 26 | } 27 | function isPromise(value) { 28 | return typeof value === "object" && value !== null && "then" in value && typeof value.then === "function"; 29 | } 30 | function isError(value) { 31 | return value instanceof Error; 32 | } 33 | function goTry(value) { 34 | try { 35 | const result = typeof value === "function" ? value() : value; 36 | if (isPromise(result)) { 37 | return result.then((resolvedValue) => success(resolvedValue)).catch((err) => failure(getErrorMessage(err))); 38 | } 39 | return success(result); 40 | } catch (err) { 41 | return failure(getErrorMessage(err)); 42 | } 43 | } 44 | function goTryRaw(value) { 45 | try { 46 | const result = typeof value === "function" ? value() : value; 47 | if (isPromise(result)) { 48 | return result.then((resolvedValue) => success(resolvedValue)).catch((err) => { 49 | if (err === void 0) { 50 | return failure(new Error("undefined")); 51 | } 52 | return failure( 53 | isError(err) ? err : new Error(String(err)) 54 | ); 55 | }); 56 | } 57 | return success(result); 58 | } catch (err) { 59 | return failure( 60 | isError(err) ? err : new Error(String(err)) 61 | ); 62 | } 63 | } 64 | 65 | exports.failure = failure; 66 | exports.goTry = goTry; 67 | exports.goTryRaw = goTryRaw; 68 | exports.isFailure = isFailure; 69 | exports.isSuccess = isSuccess; 70 | exports.success = success; 71 | -------------------------------------------------------------------------------- /dist/index.d.cts: -------------------------------------------------------------------------------- 1 | type Success = readonly [undefined, T]; 2 | type Failure = readonly [E, undefined]; 3 | type Result = Success | Failure; 4 | type MaybePromise = T | Promise; 5 | declare function isSuccess(result: Result): result is Success; 6 | declare function isFailure(result: Result): result is Failure; 7 | declare function success(value: T): Success; 8 | declare function failure(error: E): Failure; 9 | /** 10 | * Executes a function, promise, or value and returns a Result type. 11 | * If an error occurs, it returns a Failure with the error message as a string. 12 | * 13 | * @template T The type of the successful result 14 | * @param {T | Promise | (() => T | Promise)} value - The value, promise, or function to execute 15 | * @returns {Result | Promise>} A Result type or a Promise of a Result type 16 | * 17 | * @example 18 | * // With a value 19 | * const [err, result] = goTry(42); 20 | * 21 | * @example 22 | * // With a function 23 | * const [err, result] = goTry(() => JSON.parse('{"key": "value"}')); 24 | * 25 | * @example 26 | * // With a promise 27 | * const [err, result] = await goTry(fetch('https://api.example.com/data')); 28 | */ 29 | declare function goTry(fn: () => never): Result; 30 | declare function goTry(fn: () => Promise): Promise>; 31 | declare function goTry(promise: Promise): Promise>; 32 | declare function goTry(fn: () => T): Result; 33 | declare function goTry(value: T): Result; 34 | /** 35 | * Executes a function, promise, or value and returns a Result type. 36 | * If an error occurs, it returns a Failure with the raw error object. 37 | * 38 | * @template T The type of the successful result 39 | * @template E The type of the error, defaults to Error 40 | * @param {T | Promise | (() => T | Promise)} value - The value, promise, or function to execute 41 | * @returns {Result | Promise>} A Result type or a Promise of a Result type 42 | * 43 | * @example 44 | * // With a value 45 | * const [err, result] = goTryRaw(42); 46 | * 47 | * @example 48 | * // With a function 49 | * const [err, result] = goTryRaw(() => JSON.parse('{"key": "value"}')); 50 | * 51 | * @example 52 | * // With a promise 53 | * const [err, result] = await goTryRaw(fetch('https://api.example.com/data')); 54 | */ 55 | declare function goTryRaw(fn: () => never): Result; 56 | declare function goTryRaw(fn: () => Promise): Promise>; 57 | declare function goTryRaw(promise: Promise): Promise>; 58 | declare function goTryRaw(fn: () => T): Result; 59 | declare function goTryRaw(value: T): Result; 60 | 61 | export { type Failure, type MaybePromise, type Result, type Success, failure, goTry, goTryRaw, isFailure, isSuccess, success }; 62 | -------------------------------------------------------------------------------- /dist/index.d.mts: -------------------------------------------------------------------------------- 1 | type Success = readonly [undefined, T]; 2 | type Failure = readonly [E, undefined]; 3 | type Result = Success | Failure; 4 | type MaybePromise = T | Promise; 5 | declare function isSuccess(result: Result): result is Success; 6 | declare function isFailure(result: Result): result is Failure; 7 | declare function success(value: T): Success; 8 | declare function failure(error: E): Failure; 9 | /** 10 | * Executes a function, promise, or value and returns a Result type. 11 | * If an error occurs, it returns a Failure with the error message as a string. 12 | * 13 | * @template T The type of the successful result 14 | * @param {T | Promise | (() => T | Promise)} value - The value, promise, or function to execute 15 | * @returns {Result | Promise>} A Result type or a Promise of a Result type 16 | * 17 | * @example 18 | * // With a value 19 | * const [err, result] = goTry(42); 20 | * 21 | * @example 22 | * // With a function 23 | * const [err, result] = goTry(() => JSON.parse('{"key": "value"}')); 24 | * 25 | * @example 26 | * // With a promise 27 | * const [err, result] = await goTry(fetch('https://api.example.com/data')); 28 | */ 29 | declare function goTry(fn: () => never): Result; 30 | declare function goTry(fn: () => Promise): Promise>; 31 | declare function goTry(promise: Promise): Promise>; 32 | declare function goTry(fn: () => T): Result; 33 | declare function goTry(value: T): Result; 34 | /** 35 | * Executes a function, promise, or value and returns a Result type. 36 | * If an error occurs, it returns a Failure with the raw error object. 37 | * 38 | * @template T The type of the successful result 39 | * @template E The type of the error, defaults to Error 40 | * @param {T | Promise | (() => T | Promise)} value - The value, promise, or function to execute 41 | * @returns {Result | Promise>} A Result type or a Promise of a Result type 42 | * 43 | * @example 44 | * // With a value 45 | * const [err, result] = goTryRaw(42); 46 | * 47 | * @example 48 | * // With a function 49 | * const [err, result] = goTryRaw(() => JSON.parse('{"key": "value"}')); 50 | * 51 | * @example 52 | * // With a promise 53 | * const [err, result] = await goTryRaw(fetch('https://api.example.com/data')); 54 | */ 55 | declare function goTryRaw(fn: () => never): Result; 56 | declare function goTryRaw(fn: () => Promise): Promise>; 57 | declare function goTryRaw(promise: Promise): Promise>; 58 | declare function goTryRaw(fn: () => T): Result; 59 | declare function goTryRaw(value: T): Result; 60 | 61 | export { type Failure, type MaybePromise, type Result, type Success, failure, goTry, goTryRaw, isFailure, isSuccess, success }; 62 | -------------------------------------------------------------------------------- /dist/index.mjs: -------------------------------------------------------------------------------- 1 | function isSuccess(result) { 2 | return result[0] === void 0; 3 | } 4 | function isFailure(result) { 5 | return result[0] !== void 0; 6 | } 7 | function success(value) { 8 | return [void 0, value]; 9 | } 10 | function failure(error) { 11 | return [error, void 0]; 12 | } 13 | function getErrorMessage(error) { 14 | if (error === void 0) return "undefined"; 15 | if (typeof error === "string") return error; 16 | if (typeof error === "object" && error !== null && "message" in error && typeof error.message === "string") { 17 | return error.message; 18 | } 19 | try { 20 | return JSON.stringify(error); 21 | } catch { 22 | return String(error); 23 | } 24 | } 25 | function isPromise(value) { 26 | return typeof value === "object" && value !== null && "then" in value && typeof value.then === "function"; 27 | } 28 | function isError(value) { 29 | return value instanceof Error; 30 | } 31 | function goTry(value) { 32 | try { 33 | const result = typeof value === "function" ? value() : value; 34 | if (isPromise(result)) { 35 | return result.then((resolvedValue) => success(resolvedValue)).catch((err) => failure(getErrorMessage(err))); 36 | } 37 | return success(result); 38 | } catch (err) { 39 | return failure(getErrorMessage(err)); 40 | } 41 | } 42 | function goTryRaw(value) { 43 | try { 44 | const result = typeof value === "function" ? value() : value; 45 | if (isPromise(result)) { 46 | return result.then((resolvedValue) => success(resolvedValue)).catch((err) => { 47 | if (err === void 0) { 48 | return failure(new Error("undefined")); 49 | } 50 | return failure( 51 | isError(err) ? err : new Error(String(err)) 52 | ); 53 | }); 54 | } 55 | return success(result); 56 | } catch (err) { 57 | return failure( 58 | isError(err) ? err : new Error(String(err)) 59 | ); 60 | } 61 | } 62 | 63 | export { failure, goTry, goTryRaw, isFailure, isSuccess, success }; 64 | -------------------------------------------------------------------------------- /package-lock.json: -------------------------------------------------------------------------------- 1 | { 2 | "name": "go-go-try", 3 | "version": "6.0.0", 4 | "lockfileVersion": 3, 5 | "requires": true, 6 | "packages": { 7 | "": { 8 | "name": "go-go-try", 9 | "version": "6.0.0", 10 | "license": "MIT", 11 | "devDependencies": { 12 | "@ark/attest": "^0.46.0", 13 | "@biomejs/biome": "^1.9.4", 14 | "pkgroll": "^2.12.1", 15 | "tsx": "^4.19.3", 16 | "typescript": "^5.8.3", 17 | "vitest": "^3.1.2" 18 | }, 19 | "engines": { 20 | "node": ">=16" 21 | } 22 | }, 23 | "node_modules/@ark/attest": { 24 | "version": "0.46.0", 25 | "resolved": "https://registry.npmjs.org/@ark/attest/-/attest-0.46.0.tgz", 26 | "integrity": "sha512-bDo8Mtx94oFkhozao9rjoWf1/MOV4lakpoKtPvIFfHceE3M3jVqIOVY46Xh1TibMhjQ1vMtd55PcfllHYjbm8w==", 27 | "dev": true, 28 | "license": "MIT", 29 | "dependencies": { 30 | "@ark/fs": "0.46.0", 31 | "@ark/util": "0.46.0", 32 | "@prettier/sync": "0.5.5", 33 | "@typescript/analyze-trace": "0.10.1", 34 | "@typescript/vfs": "1.6.1", 35 | "arktype": "2.1.20", 36 | "prettier": "3.5.3" 37 | }, 38 | "bin": { 39 | "attest": "out/cli/cli.js" 40 | }, 41 | "peerDependencies": { 42 | "typescript": "*" 43 | } 44 | }, 45 | "node_modules/@ark/fs": { 46 | "version": "0.46.0", 47 | "resolved": "https://registry.npmjs.org/@ark/fs/-/fs-0.46.0.tgz", 48 | "integrity": "sha512-lBW6Vv6dZ74Gcc+zvJP8gjZACMo5o6hEuOvAtX6EJ5xNYBmX7nrXQaDdRfQNGDzgaX5UHGqi/vxk5moK94K7Yw==", 49 | "dev": true, 50 | "license": "MIT" 51 | }, 52 | "node_modules/@ark/schema": { 53 | "version": "0.46.0", 54 | "resolved": "https://registry.npmjs.org/@ark/schema/-/schema-0.46.0.tgz", 55 | "integrity": "sha512-c2UQdKgP2eqqDArfBqQIJppxJHvNNXuQPeuSPlDML4rjw+f1cu0qAlzOG4b8ujgm9ctIDWwhpyw6gjG5ledIVQ==", 56 | "dev": true, 57 | "license": "MIT", 58 | "dependencies": { 59 | "@ark/util": "0.46.0" 60 | } 61 | }, 62 | "node_modules/@ark/util": { 63 | "version": "0.46.0", 64 | "resolved": "https://registry.npmjs.org/@ark/util/-/util-0.46.0.tgz", 65 | "integrity": "sha512-JPy/NGWn/lvf1WmGCPw2VGpBg5utZraE84I7wli18EDF3p3zc/e9WolT35tINeZO3l7C77SjqRJeAUoT0CvMRg==", 66 | "dev": true, 67 | "license": "MIT" 68 | }, 69 | "node_modules/@biomejs/biome": { 70 | "version": "1.9.4", 71 | "resolved": "https://registry.npmjs.org/@biomejs/biome/-/biome-1.9.4.tgz", 72 | "integrity": "sha512-1rkd7G70+o9KkTn5KLmDYXihGoTaIGO9PIIN2ZB7UJxFrWw04CZHPYiMRjYsaDvVV7hP1dYNRLxSANLaBFGpog==", 73 | "dev": true, 74 | "hasInstallScript": true, 75 | "license": "MIT OR Apache-2.0", 76 | "bin": { 77 | "biome": "bin/biome" 78 | }, 79 | "engines": { 80 | "node": ">=14.21.3" 81 | }, 82 | "funding": { 83 | "type": "opencollective", 84 | "url": "https://opencollective.com/biome" 85 | }, 86 | "optionalDependencies": { 87 | "@biomejs/cli-darwin-arm64": "1.9.4", 88 | "@biomejs/cli-darwin-x64": "1.9.4", 89 | "@biomejs/cli-linux-arm64": "1.9.4", 90 | "@biomejs/cli-linux-arm64-musl": "1.9.4", 91 | "@biomejs/cli-linux-x64": "1.9.4", 92 | "@biomejs/cli-linux-x64-musl": "1.9.4", 93 | "@biomejs/cli-win32-arm64": "1.9.4", 94 | "@biomejs/cli-win32-x64": "1.9.4" 95 | } 96 | }, 97 | "node_modules/@biomejs/cli-darwin-arm64": { 98 | "version": "1.9.4", 99 | "resolved": "https://registry.npmjs.org/@biomejs/cli-darwin-arm64/-/cli-darwin-arm64-1.9.4.tgz", 100 | "integrity": "sha512-bFBsPWrNvkdKrNCYeAp+xo2HecOGPAy9WyNyB/jKnnedgzl4W4Hb9ZMzYNbf8dMCGmUdSavlYHiR01QaYR58cw==", 101 | "cpu": [ 102 | "arm64" 103 | ], 104 | "dev": true, 105 | "license": "MIT OR Apache-2.0", 106 | "optional": true, 107 | "os": [ 108 | "darwin" 109 | ], 110 | "engines": { 111 | "node": ">=14.21.3" 112 | } 113 | }, 114 | "node_modules/@biomejs/cli-darwin-x64": { 115 | "version": "1.9.4", 116 | "resolved": "https://registry.npmjs.org/@biomejs/cli-darwin-x64/-/cli-darwin-x64-1.9.4.tgz", 117 | "integrity": "sha512-ngYBh/+bEedqkSevPVhLP4QfVPCpb+4BBe2p7Xs32dBgs7rh9nY2AIYUL6BgLw1JVXV8GlpKmb/hNiuIxfPfZg==", 118 | "cpu": [ 119 | "x64" 120 | ], 121 | "dev": true, 122 | "license": "MIT OR Apache-2.0", 123 | "optional": true, 124 | "os": [ 125 | "darwin" 126 | ], 127 | "engines": { 128 | "node": ">=14.21.3" 129 | } 130 | }, 131 | "node_modules/@biomejs/cli-linux-arm64": { 132 | "version": "1.9.4", 133 | "resolved": "https://registry.npmjs.org/@biomejs/cli-linux-arm64/-/cli-linux-arm64-1.9.4.tgz", 134 | "integrity": "sha512-fJIW0+LYujdjUgJJuwesP4EjIBl/N/TcOX3IvIHJQNsAqvV2CHIogsmA94BPG6jZATS4Hi+xv4SkBBQSt1N4/g==", 135 | "cpu": [ 136 | "arm64" 137 | ], 138 | "dev": true, 139 | "license": "MIT OR Apache-2.0", 140 | "optional": true, 141 | "os": [ 142 | "linux" 143 | ], 144 | "engines": { 145 | "node": ">=14.21.3" 146 | } 147 | }, 148 | "node_modules/@biomejs/cli-linux-arm64-musl": { 149 | "version": "1.9.4", 150 | "resolved": "https://registry.npmjs.org/@biomejs/cli-linux-arm64-musl/-/cli-linux-arm64-musl-1.9.4.tgz", 151 | "integrity": "sha512-v665Ct9WCRjGa8+kTr0CzApU0+XXtRgwmzIf1SeKSGAv+2scAlW6JR5PMFo6FzqqZ64Po79cKODKf3/AAmECqA==", 152 | "cpu": [ 153 | "arm64" 154 | ], 155 | "dev": true, 156 | "license": "MIT OR Apache-2.0", 157 | "optional": true, 158 | "os": [ 159 | "linux" 160 | ], 161 | "engines": { 162 | "node": ">=14.21.3" 163 | } 164 | }, 165 | "node_modules/@biomejs/cli-linux-x64": { 166 | "version": "1.9.4", 167 | "resolved": "https://registry.npmjs.org/@biomejs/cli-linux-x64/-/cli-linux-x64-1.9.4.tgz", 168 | "integrity": "sha512-lRCJv/Vi3Vlwmbd6K+oQ0KhLHMAysN8lXoCI7XeHlxaajk06u7G+UsFSO01NAs5iYuWKmVZjmiOzJ0OJmGsMwg==", 169 | "cpu": [ 170 | "x64" 171 | ], 172 | "dev": true, 173 | "license": "MIT OR Apache-2.0", 174 | "optional": true, 175 | "os": [ 176 | "linux" 177 | ], 178 | "engines": { 179 | "node": ">=14.21.3" 180 | } 181 | }, 182 | "node_modules/@biomejs/cli-linux-x64-musl": { 183 | "version": "1.9.4", 184 | "resolved": "https://registry.npmjs.org/@biomejs/cli-linux-x64-musl/-/cli-linux-x64-musl-1.9.4.tgz", 185 | "integrity": "sha512-gEhi/jSBhZ2m6wjV530Yy8+fNqG8PAinM3oV7CyO+6c3CEh16Eizm21uHVsyVBEB6RIM8JHIl6AGYCv6Q6Q9Tg==", 186 | "cpu": [ 187 | "x64" 188 | ], 189 | "dev": true, 190 | "license": "MIT OR Apache-2.0", 191 | "optional": true, 192 | "os": [ 193 | "linux" 194 | ], 195 | "engines": { 196 | "node": ">=14.21.3" 197 | } 198 | }, 199 | "node_modules/@biomejs/cli-win32-arm64": { 200 | "version": "1.9.4", 201 | "resolved": "https://registry.npmjs.org/@biomejs/cli-win32-arm64/-/cli-win32-arm64-1.9.4.tgz", 202 | "integrity": "sha512-tlbhLk+WXZmgwoIKwHIHEBZUwxml7bRJgk0X2sPyNR3S93cdRq6XulAZRQJ17FYGGzWne0fgrXBKpl7l4M87Hg==", 203 | "cpu": [ 204 | "arm64" 205 | ], 206 | "dev": true, 207 | "license": "MIT OR Apache-2.0", 208 | "optional": true, 209 | "os": [ 210 | "win32" 211 | ], 212 | "engines": { 213 | "node": ">=14.21.3" 214 | } 215 | }, 216 | "node_modules/@biomejs/cli-win32-x64": { 217 | "version": "1.9.4", 218 | "resolved": "https://registry.npmjs.org/@biomejs/cli-win32-x64/-/cli-win32-x64-1.9.4.tgz", 219 | "integrity": "sha512-8Y5wMhVIPaWe6jw2H+KlEm4wP/f7EW3810ZLmDlrEEy5KvBsb9ECEfu/kMWD484ijfQ8+nIi0giMgu9g1UAuuA==", 220 | "cpu": [ 221 | "x64" 222 | ], 223 | "dev": true, 224 | "license": "MIT OR Apache-2.0", 225 | "optional": true, 226 | "os": [ 227 | "win32" 228 | ], 229 | "engines": { 230 | "node": ">=14.21.3" 231 | } 232 | }, 233 | "node_modules/@esbuild/aix-ppc64": { 234 | "version": "0.25.2", 235 | "resolved": "https://registry.npmjs.org/@esbuild/aix-ppc64/-/aix-ppc64-0.25.2.tgz", 236 | "integrity": "sha512-wCIboOL2yXZym2cgm6mlA742s9QeJ8DjGVaL39dLN4rRwrOgOyYSnOaFPhKZGLb2ngj4EyfAFjsNJwPXZvseag==", 237 | "cpu": [ 238 | "ppc64" 239 | ], 240 | "dev": true, 241 | "license": "MIT", 242 | "optional": true, 243 | "os": [ 244 | "aix" 245 | ], 246 | "engines": { 247 | "node": ">=18" 248 | } 249 | }, 250 | "node_modules/@esbuild/android-arm": { 251 | "version": "0.25.2", 252 | "resolved": "https://registry.npmjs.org/@esbuild/android-arm/-/android-arm-0.25.2.tgz", 253 | "integrity": "sha512-NQhH7jFstVY5x8CKbcfa166GoV0EFkaPkCKBQkdPJFvo5u+nGXLEH/ooniLb3QI8Fk58YAx7nsPLozUWfCBOJA==", 254 | "cpu": [ 255 | "arm" 256 | ], 257 | "dev": true, 258 | "license": "MIT", 259 | "optional": true, 260 | "os": [ 261 | "android" 262 | ], 263 | "engines": { 264 | "node": ">=18" 265 | } 266 | }, 267 | "node_modules/@esbuild/android-arm64": { 268 | "version": "0.25.2", 269 | "resolved": "https://registry.npmjs.org/@esbuild/android-arm64/-/android-arm64-0.25.2.tgz", 270 | "integrity": "sha512-5ZAX5xOmTligeBaeNEPnPaeEuah53Id2tX4c2CVP3JaROTH+j4fnfHCkr1PjXMd78hMst+TlkfKcW/DlTq0i4w==", 271 | "cpu": [ 272 | "arm64" 273 | ], 274 | "dev": true, 275 | "license": "MIT", 276 | "optional": true, 277 | "os": [ 278 | "android" 279 | ], 280 | "engines": { 281 | "node": ">=18" 282 | } 283 | }, 284 | "node_modules/@esbuild/android-x64": { 285 | "version": "0.25.2", 286 | "resolved": "https://registry.npmjs.org/@esbuild/android-x64/-/android-x64-0.25.2.tgz", 287 | "integrity": "sha512-Ffcx+nnma8Sge4jzddPHCZVRvIfQ0kMsUsCMcJRHkGJ1cDmhe4SsrYIjLUKn1xpHZybmOqCWwB0zQvsjdEHtkg==", 288 | "cpu": [ 289 | "x64" 290 | ], 291 | "dev": true, 292 | "license": "MIT", 293 | "optional": true, 294 | "os": [ 295 | "android" 296 | ], 297 | "engines": { 298 | "node": ">=18" 299 | } 300 | }, 301 | "node_modules/@esbuild/darwin-arm64": { 302 | "version": "0.25.2", 303 | "resolved": "https://registry.npmjs.org/@esbuild/darwin-arm64/-/darwin-arm64-0.25.2.tgz", 304 | "integrity": "sha512-MpM6LUVTXAzOvN4KbjzU/q5smzryuoNjlriAIx+06RpecwCkL9JpenNzpKd2YMzLJFOdPqBpuub6eVRP5IgiSA==", 305 | "cpu": [ 306 | "arm64" 307 | ], 308 | "dev": true, 309 | "license": "MIT", 310 | "optional": true, 311 | "os": [ 312 | "darwin" 313 | ], 314 | "engines": { 315 | "node": ">=18" 316 | } 317 | }, 318 | "node_modules/@esbuild/darwin-x64": { 319 | "version": "0.25.2", 320 | "resolved": "https://registry.npmjs.org/@esbuild/darwin-x64/-/darwin-x64-0.25.2.tgz", 321 | "integrity": "sha512-5eRPrTX7wFyuWe8FqEFPG2cU0+butQQVNcT4sVipqjLYQjjh8a8+vUTfgBKM88ObB85ahsnTwF7PSIt6PG+QkA==", 322 | "cpu": [ 323 | "x64" 324 | ], 325 | "dev": true, 326 | "license": "MIT", 327 | "optional": true, 328 | "os": [ 329 | "darwin" 330 | ], 331 | "engines": { 332 | "node": ">=18" 333 | } 334 | }, 335 | "node_modules/@esbuild/freebsd-arm64": { 336 | "version": "0.25.2", 337 | "resolved": "https://registry.npmjs.org/@esbuild/freebsd-arm64/-/freebsd-arm64-0.25.2.tgz", 338 | "integrity": "sha512-mLwm4vXKiQ2UTSX4+ImyiPdiHjiZhIaE9QvC7sw0tZ6HoNMjYAqQpGyui5VRIi5sGd+uWq940gdCbY3VLvsO1w==", 339 | "cpu": [ 340 | "arm64" 341 | ], 342 | "dev": true, 343 | "license": "MIT", 344 | "optional": true, 345 | "os": [ 346 | "freebsd" 347 | ], 348 | "engines": { 349 | "node": ">=18" 350 | } 351 | }, 352 | "node_modules/@esbuild/freebsd-x64": { 353 | "version": "0.25.2", 354 | "resolved": "https://registry.npmjs.org/@esbuild/freebsd-x64/-/freebsd-x64-0.25.2.tgz", 355 | "integrity": "sha512-6qyyn6TjayJSwGpm8J9QYYGQcRgc90nmfdUb0O7pp1s4lTY+9D0H9O02v5JqGApUyiHOtkz6+1hZNvNtEhbwRQ==", 356 | "cpu": [ 357 | "x64" 358 | ], 359 | "dev": true, 360 | "license": "MIT", 361 | "optional": true, 362 | "os": [ 363 | "freebsd" 364 | ], 365 | "engines": { 366 | "node": ">=18" 367 | } 368 | }, 369 | "node_modules/@esbuild/linux-arm": { 370 | "version": "0.25.2", 371 | "resolved": "https://registry.npmjs.org/@esbuild/linux-arm/-/linux-arm-0.25.2.tgz", 372 | "integrity": "sha512-UHBRgJcmjJv5oeQF8EpTRZs/1knq6loLxTsjc3nxO9eXAPDLcWW55flrMVc97qFPbmZP31ta1AZVUKQzKTzb0g==", 373 | "cpu": [ 374 | "arm" 375 | ], 376 | "dev": true, 377 | "license": "MIT", 378 | "optional": true, 379 | "os": [ 380 | "linux" 381 | ], 382 | "engines": { 383 | "node": ">=18" 384 | } 385 | }, 386 | "node_modules/@esbuild/linux-arm64": { 387 | "version": "0.25.2", 388 | "resolved": "https://registry.npmjs.org/@esbuild/linux-arm64/-/linux-arm64-0.25.2.tgz", 389 | "integrity": "sha512-gq/sjLsOyMT19I8obBISvhoYiZIAaGF8JpeXu1u8yPv8BE5HlWYobmlsfijFIZ9hIVGYkbdFhEqC0NvM4kNO0g==", 390 | "cpu": [ 391 | "arm64" 392 | ], 393 | "dev": true, 394 | "license": "MIT", 395 | "optional": true, 396 | "os": [ 397 | "linux" 398 | ], 399 | "engines": { 400 | "node": ">=18" 401 | } 402 | }, 403 | "node_modules/@esbuild/linux-ia32": { 404 | "version": "0.25.2", 405 | "resolved": "https://registry.npmjs.org/@esbuild/linux-ia32/-/linux-ia32-0.25.2.tgz", 406 | "integrity": "sha512-bBYCv9obgW2cBP+2ZWfjYTU+f5cxRoGGQ5SeDbYdFCAZpYWrfjjfYwvUpP8MlKbP0nwZ5gyOU/0aUzZ5HWPuvQ==", 407 | "cpu": [ 408 | "ia32" 409 | ], 410 | "dev": true, 411 | "license": "MIT", 412 | "optional": true, 413 | "os": [ 414 | "linux" 415 | ], 416 | "engines": { 417 | "node": ">=18" 418 | } 419 | }, 420 | "node_modules/@esbuild/linux-loong64": { 421 | "version": "0.25.2", 422 | "resolved": "https://registry.npmjs.org/@esbuild/linux-loong64/-/linux-loong64-0.25.2.tgz", 423 | "integrity": "sha512-SHNGiKtvnU2dBlM5D8CXRFdd+6etgZ9dXfaPCeJtz+37PIUlixvlIhI23L5khKXs3DIzAn9V8v+qb1TRKrgT5w==", 424 | "cpu": [ 425 | "loong64" 426 | ], 427 | "dev": true, 428 | "license": "MIT", 429 | "optional": true, 430 | "os": [ 431 | "linux" 432 | ], 433 | "engines": { 434 | "node": ">=18" 435 | } 436 | }, 437 | "node_modules/@esbuild/linux-mips64el": { 438 | "version": "0.25.2", 439 | "resolved": "https://registry.npmjs.org/@esbuild/linux-mips64el/-/linux-mips64el-0.25.2.tgz", 440 | "integrity": "sha512-hDDRlzE6rPeoj+5fsADqdUZl1OzqDYow4TB4Y/3PlKBD0ph1e6uPHzIQcv2Z65u2K0kpeByIyAjCmjn1hJgG0Q==", 441 | "cpu": [ 442 | "mips64el" 443 | ], 444 | "dev": true, 445 | "license": "MIT", 446 | "optional": true, 447 | "os": [ 448 | "linux" 449 | ], 450 | "engines": { 451 | "node": ">=18" 452 | } 453 | }, 454 | "node_modules/@esbuild/linux-ppc64": { 455 | "version": "0.25.2", 456 | "resolved": "https://registry.npmjs.org/@esbuild/linux-ppc64/-/linux-ppc64-0.25.2.tgz", 457 | "integrity": "sha512-tsHu2RRSWzipmUi9UBDEzc0nLc4HtpZEI5Ba+Omms5456x5WaNuiG3u7xh5AO6sipnJ9r4cRWQB2tUjPyIkc6g==", 458 | "cpu": [ 459 | "ppc64" 460 | ], 461 | "dev": true, 462 | "license": "MIT", 463 | "optional": true, 464 | "os": [ 465 | "linux" 466 | ], 467 | "engines": { 468 | "node": ">=18" 469 | } 470 | }, 471 | "node_modules/@esbuild/linux-riscv64": { 472 | "version": "0.25.2", 473 | "resolved": "https://registry.npmjs.org/@esbuild/linux-riscv64/-/linux-riscv64-0.25.2.tgz", 474 | "integrity": "sha512-k4LtpgV7NJQOml/10uPU0s4SAXGnowi5qBSjaLWMojNCUICNu7TshqHLAEbkBdAszL5TabfvQ48kK84hyFzjnw==", 475 | "cpu": [ 476 | "riscv64" 477 | ], 478 | "dev": true, 479 | "license": "MIT", 480 | "optional": true, 481 | "os": [ 482 | "linux" 483 | ], 484 | "engines": { 485 | "node": ">=18" 486 | } 487 | }, 488 | "node_modules/@esbuild/linux-s390x": { 489 | "version": "0.25.2", 490 | "resolved": "https://registry.npmjs.org/@esbuild/linux-s390x/-/linux-s390x-0.25.2.tgz", 491 | "integrity": "sha512-GRa4IshOdvKY7M/rDpRR3gkiTNp34M0eLTaC1a08gNrh4u488aPhuZOCpkF6+2wl3zAN7L7XIpOFBhnaE3/Q8Q==", 492 | "cpu": [ 493 | "s390x" 494 | ], 495 | "dev": true, 496 | "license": "MIT", 497 | "optional": true, 498 | "os": [ 499 | "linux" 500 | ], 501 | "engines": { 502 | "node": ">=18" 503 | } 504 | }, 505 | "node_modules/@esbuild/linux-x64": { 506 | "version": "0.25.2", 507 | "resolved": "https://registry.npmjs.org/@esbuild/linux-x64/-/linux-x64-0.25.2.tgz", 508 | "integrity": "sha512-QInHERlqpTTZ4FRB0fROQWXcYRD64lAoiegezDunLpalZMjcUcld3YzZmVJ2H/Cp0wJRZ8Xtjtj0cEHhYc/uUg==", 509 | "cpu": [ 510 | "x64" 511 | ], 512 | "dev": true, 513 | "license": "MIT", 514 | "optional": true, 515 | "os": [ 516 | "linux" 517 | ], 518 | "engines": { 519 | "node": ">=18" 520 | } 521 | }, 522 | "node_modules/@esbuild/netbsd-arm64": { 523 | "version": "0.25.2", 524 | "resolved": "https://registry.npmjs.org/@esbuild/netbsd-arm64/-/netbsd-arm64-0.25.2.tgz", 525 | "integrity": "sha512-talAIBoY5M8vHc6EeI2WW9d/CkiO9MQJ0IOWX8hrLhxGbro/vBXJvaQXefW2cP0z0nQVTdQ/eNyGFV1GSKrxfw==", 526 | "cpu": [ 527 | "arm64" 528 | ], 529 | "dev": true, 530 | "license": "MIT", 531 | "optional": true, 532 | "os": [ 533 | "netbsd" 534 | ], 535 | "engines": { 536 | "node": ">=18" 537 | } 538 | }, 539 | "node_modules/@esbuild/netbsd-x64": { 540 | "version": "0.25.2", 541 | "resolved": "https://registry.npmjs.org/@esbuild/netbsd-x64/-/netbsd-x64-0.25.2.tgz", 542 | "integrity": "sha512-voZT9Z+tpOxrvfKFyfDYPc4DO4rk06qamv1a/fkuzHpiVBMOhpjK+vBmWM8J1eiB3OLSMFYNaOaBNLXGChf5tg==", 543 | "cpu": [ 544 | "x64" 545 | ], 546 | "dev": true, 547 | "license": "MIT", 548 | "optional": true, 549 | "os": [ 550 | "netbsd" 551 | ], 552 | "engines": { 553 | "node": ">=18" 554 | } 555 | }, 556 | "node_modules/@esbuild/openbsd-arm64": { 557 | "version": "0.25.2", 558 | "resolved": "https://registry.npmjs.org/@esbuild/openbsd-arm64/-/openbsd-arm64-0.25.2.tgz", 559 | "integrity": "sha512-dcXYOC6NXOqcykeDlwId9kB6OkPUxOEqU+rkrYVqJbK2hagWOMrsTGsMr8+rW02M+d5Op5NNlgMmjzecaRf7Tg==", 560 | "cpu": [ 561 | "arm64" 562 | ], 563 | "dev": true, 564 | "license": "MIT", 565 | "optional": true, 566 | "os": [ 567 | "openbsd" 568 | ], 569 | "engines": { 570 | "node": ">=18" 571 | } 572 | }, 573 | "node_modules/@esbuild/openbsd-x64": { 574 | "version": "0.25.2", 575 | "resolved": "https://registry.npmjs.org/@esbuild/openbsd-x64/-/openbsd-x64-0.25.2.tgz", 576 | "integrity": "sha512-t/TkWwahkH0Tsgoq1Ju7QfgGhArkGLkF1uYz8nQS/PPFlXbP5YgRpqQR3ARRiC2iXoLTWFxc6DJMSK10dVXluw==", 577 | "cpu": [ 578 | "x64" 579 | ], 580 | "dev": true, 581 | "license": "MIT", 582 | "optional": true, 583 | "os": [ 584 | "openbsd" 585 | ], 586 | "engines": { 587 | "node": ">=18" 588 | } 589 | }, 590 | "node_modules/@esbuild/sunos-x64": { 591 | "version": "0.25.2", 592 | "resolved": "https://registry.npmjs.org/@esbuild/sunos-x64/-/sunos-x64-0.25.2.tgz", 593 | "integrity": "sha512-cfZH1co2+imVdWCjd+D1gf9NjkchVhhdpgb1q5y6Hcv9TP6Zi9ZG/beI3ig8TvwT9lH9dlxLq5MQBBgwuj4xvA==", 594 | "cpu": [ 595 | "x64" 596 | ], 597 | "dev": true, 598 | "license": "MIT", 599 | "optional": true, 600 | "os": [ 601 | "sunos" 602 | ], 603 | "engines": { 604 | "node": ">=18" 605 | } 606 | }, 607 | "node_modules/@esbuild/win32-arm64": { 608 | "version": "0.25.2", 609 | "resolved": "https://registry.npmjs.org/@esbuild/win32-arm64/-/win32-arm64-0.25.2.tgz", 610 | "integrity": "sha512-7Loyjh+D/Nx/sOTzV8vfbB3GJuHdOQyrOryFdZvPHLf42Tk9ivBU5Aedi7iyX+x6rbn2Mh68T4qq1SDqJBQO5Q==", 611 | "cpu": [ 612 | "arm64" 613 | ], 614 | "dev": true, 615 | "license": "MIT", 616 | "optional": true, 617 | "os": [ 618 | "win32" 619 | ], 620 | "engines": { 621 | "node": ">=18" 622 | } 623 | }, 624 | "node_modules/@esbuild/win32-ia32": { 625 | "version": "0.25.2", 626 | "resolved": "https://registry.npmjs.org/@esbuild/win32-ia32/-/win32-ia32-0.25.2.tgz", 627 | "integrity": "sha512-WRJgsz9un0nqZJ4MfhabxaD9Ft8KioqU3JMinOTvobbX6MOSUigSBlogP8QB3uxpJDsFS6yN+3FDBdqE5lg9kg==", 628 | "cpu": [ 629 | "ia32" 630 | ], 631 | "dev": true, 632 | "license": "MIT", 633 | "optional": true, 634 | "os": [ 635 | "win32" 636 | ], 637 | "engines": { 638 | "node": ">=18" 639 | } 640 | }, 641 | "node_modules/@esbuild/win32-x64": { 642 | "version": "0.25.2", 643 | "resolved": "https://registry.npmjs.org/@esbuild/win32-x64/-/win32-x64-0.25.2.tgz", 644 | "integrity": "sha512-kM3HKb16VIXZyIeVrM1ygYmZBKybX8N4p754bw390wGO3Tf2j4L2/WYL+4suWujpgf6GBYs3jv7TyUivdd05JA==", 645 | "cpu": [ 646 | "x64" 647 | ], 648 | "dev": true, 649 | "license": "MIT", 650 | "optional": true, 651 | "os": [ 652 | "win32" 653 | ], 654 | "engines": { 655 | "node": ">=18" 656 | } 657 | }, 658 | "node_modules/@jridgewell/sourcemap-codec": { 659 | "version": "1.5.0", 660 | "resolved": "https://registry.npmjs.org/@jridgewell/sourcemap-codec/-/sourcemap-codec-1.5.0.tgz", 661 | "integrity": "sha512-gv3ZRaISU3fjPAgNsriBRqGWQL6quFx04YMPW/zD8XMLsU32mhCCbfbO6KZFLjvYpCZ8zyDEgqsgf+PwPaM7GQ==", 662 | "dev": true, 663 | "license": "MIT" 664 | }, 665 | "node_modules/@nodelib/fs.scandir": { 666 | "version": "2.1.5", 667 | "resolved": "https://registry.npmjs.org/@nodelib/fs.scandir/-/fs.scandir-2.1.5.tgz", 668 | "integrity": "sha512-vq24Bq3ym5HEQm2NKCr3yXDwjc7vTsEThRDnkp2DK9p1uqLR+DHurm/NOTo0KG7HYHU7eppKZj3MyqYuMBf62g==", 669 | "dev": true, 670 | "license": "MIT", 671 | "dependencies": { 672 | "@nodelib/fs.stat": "2.0.5", 673 | "run-parallel": "^1.1.9" 674 | }, 675 | "engines": { 676 | "node": ">= 8" 677 | } 678 | }, 679 | "node_modules/@nodelib/fs.stat": { 680 | "version": "2.0.5", 681 | "resolved": "https://registry.npmjs.org/@nodelib/fs.stat/-/fs.stat-2.0.5.tgz", 682 | "integrity": "sha512-RkhPPp2zrqDAQA/2jNhnztcPAlv64XdhIp7a7454A5ovI7Bukxgt7MX7udwAu3zg1DcpPU0rz3VV1SeaqvY4+A==", 683 | "dev": true, 684 | "license": "MIT", 685 | "engines": { 686 | "node": ">= 8" 687 | } 688 | }, 689 | "node_modules/@nodelib/fs.walk": { 690 | "version": "1.2.8", 691 | "resolved": "https://registry.npmjs.org/@nodelib/fs.walk/-/fs.walk-1.2.8.tgz", 692 | "integrity": "sha512-oGB+UxlgWcgQkgwo8GcEGwemoTFt3FIO9ababBmaGwXIoBKZ+GTy0pP185beGg7Llih/NSHSV2XAs1lnznocSg==", 693 | "dev": true, 694 | "license": "MIT", 695 | "dependencies": { 696 | "@nodelib/fs.scandir": "2.1.5", 697 | "fastq": "^1.6.0" 698 | }, 699 | "engines": { 700 | "node": ">= 8" 701 | } 702 | }, 703 | "node_modules/@prettier/sync": { 704 | "version": "0.5.5", 705 | "resolved": "https://registry.npmjs.org/@prettier/sync/-/sync-0.5.5.tgz", 706 | "integrity": "sha512-6BMtNr7aQhyNcGzmumkL0tgr1YQGfm9d7ZdmRpWqWuqpc9vZBind4xMe5NMiRECOhjuSiWHfBWLBnXkpeE90bw==", 707 | "dev": true, 708 | "license": "MIT", 709 | "dependencies": { 710 | "make-synchronized": "^0.4.2" 711 | }, 712 | "funding": { 713 | "url": "https://github.com/prettier/prettier-synchronized?sponsor=1" 714 | }, 715 | "peerDependencies": { 716 | "prettier": "*" 717 | } 718 | }, 719 | "node_modules/@rollup/plugin-alias": { 720 | "version": "5.1.1", 721 | "resolved": "https://registry.npmjs.org/@rollup/plugin-alias/-/plugin-alias-5.1.1.tgz", 722 | "integrity": "sha512-PR9zDb+rOzkRb2VD+EuKB7UC41vU5DIwZ5qqCpk0KJudcWAyi8rvYOhS7+L5aZCspw1stTViLgN5v6FF1p5cgQ==", 723 | "dev": true, 724 | "license": "MIT", 725 | "engines": { 726 | "node": ">=14.0.0" 727 | }, 728 | "peerDependencies": { 729 | "rollup": "^1.20.0||^2.0.0||^3.0.0||^4.0.0" 730 | }, 731 | "peerDependenciesMeta": { 732 | "rollup": { 733 | "optional": true 734 | } 735 | } 736 | }, 737 | "node_modules/@rollup/plugin-commonjs": { 738 | "version": "28.0.3", 739 | "resolved": "https://registry.npmjs.org/@rollup/plugin-commonjs/-/plugin-commonjs-28.0.3.tgz", 740 | "integrity": "sha512-pyltgilam1QPdn+Zd9gaCfOLcnjMEJ9gV+bTw6/r73INdvzf1ah9zLIJBm+kW7R6IUFIQ1YO+VqZtYxZNWFPEQ==", 741 | "dev": true, 742 | "license": "MIT", 743 | "dependencies": { 744 | "@rollup/pluginutils": "^5.0.1", 745 | "commondir": "^1.0.1", 746 | "estree-walker": "^2.0.2", 747 | "fdir": "^6.2.0", 748 | "is-reference": "1.2.1", 749 | "magic-string": "^0.30.3", 750 | "picomatch": "^4.0.2" 751 | }, 752 | "engines": { 753 | "node": ">=16.0.0 || 14 >= 14.17" 754 | }, 755 | "peerDependencies": { 756 | "rollup": "^2.68.0||^3.0.0||^4.0.0" 757 | }, 758 | "peerDependenciesMeta": { 759 | "rollup": { 760 | "optional": true 761 | } 762 | } 763 | }, 764 | "node_modules/@rollup/plugin-dynamic-import-vars": { 765 | "version": "2.1.5", 766 | "resolved": "https://registry.npmjs.org/@rollup/plugin-dynamic-import-vars/-/plugin-dynamic-import-vars-2.1.5.tgz", 767 | "integrity": "sha512-Mymi24fd9hlRifdZV/jYIFj1dn99F34imiYu3KzlAcgBcRi3i9SucgW/VRo5SQ9K4NuQ7dCep6pFWgNyhRdFHQ==", 768 | "dev": true, 769 | "license": "MIT", 770 | "dependencies": { 771 | "@rollup/pluginutils": "^5.0.1", 772 | "astring": "^1.8.5", 773 | "estree-walker": "^2.0.2", 774 | "fast-glob": "^3.2.12", 775 | "magic-string": "^0.30.3" 776 | }, 777 | "engines": { 778 | "node": ">=14.0.0" 779 | }, 780 | "peerDependencies": { 781 | "rollup": "^1.20.0||^2.0.0||^3.0.0||^4.0.0" 782 | }, 783 | "peerDependenciesMeta": { 784 | "rollup": { 785 | "optional": true 786 | } 787 | } 788 | }, 789 | "node_modules/@rollup/plugin-inject": { 790 | "version": "5.0.5", 791 | "resolved": "https://registry.npmjs.org/@rollup/plugin-inject/-/plugin-inject-5.0.5.tgz", 792 | "integrity": "sha512-2+DEJbNBoPROPkgTDNe8/1YXWcqxbN5DTjASVIOx8HS+pITXushyNiBV56RB08zuptzz8gT3YfkqriTBVycepg==", 793 | "dev": true, 794 | "license": "MIT", 795 | "dependencies": { 796 | "@rollup/pluginutils": "^5.0.1", 797 | "estree-walker": "^2.0.2", 798 | "magic-string": "^0.30.3" 799 | }, 800 | "engines": { 801 | "node": ">=14.0.0" 802 | }, 803 | "peerDependencies": { 804 | "rollup": "^1.20.0||^2.0.0||^3.0.0||^4.0.0" 805 | }, 806 | "peerDependenciesMeta": { 807 | "rollup": { 808 | "optional": true 809 | } 810 | } 811 | }, 812 | "node_modules/@rollup/plugin-json": { 813 | "version": "6.1.0", 814 | "resolved": "https://registry.npmjs.org/@rollup/plugin-json/-/plugin-json-6.1.0.tgz", 815 | "integrity": "sha512-EGI2te5ENk1coGeADSIwZ7G2Q8CJS2sF120T7jLw4xFw9n7wIOXHo+kIYRAoVpJAN+kmqZSoO3Fp4JtoNF4ReA==", 816 | "dev": true, 817 | "license": "MIT", 818 | "dependencies": { 819 | "@rollup/pluginutils": "^5.1.0" 820 | }, 821 | "engines": { 822 | "node": ">=14.0.0" 823 | }, 824 | "peerDependencies": { 825 | "rollup": "^1.20.0||^2.0.0||^3.0.0||^4.0.0" 826 | }, 827 | "peerDependenciesMeta": { 828 | "rollup": { 829 | "optional": true 830 | } 831 | } 832 | }, 833 | "node_modules/@rollup/plugin-node-resolve": { 834 | "version": "16.0.1", 835 | "resolved": "https://registry.npmjs.org/@rollup/plugin-node-resolve/-/plugin-node-resolve-16.0.1.tgz", 836 | "integrity": "sha512-tk5YCxJWIG81umIvNkSod2qK5KyQW19qcBF/B78n1bjtOON6gzKoVeSzAE8yHCZEDmqkHKkxplExA8KzdJLJpA==", 837 | "dev": true, 838 | "license": "MIT", 839 | "dependencies": { 840 | "@rollup/pluginutils": "^5.0.1", 841 | "@types/resolve": "1.20.2", 842 | "deepmerge": "^4.2.2", 843 | "is-module": "^1.0.0", 844 | "resolve": "^1.22.1" 845 | }, 846 | "engines": { 847 | "node": ">=14.0.0" 848 | }, 849 | "peerDependencies": { 850 | "rollup": "^2.78.0||^3.0.0||^4.0.0" 851 | }, 852 | "peerDependenciesMeta": { 853 | "rollup": { 854 | "optional": true 855 | } 856 | } 857 | }, 858 | "node_modules/@rollup/pluginutils": { 859 | "version": "5.1.4", 860 | "resolved": "https://registry.npmjs.org/@rollup/pluginutils/-/pluginutils-5.1.4.tgz", 861 | "integrity": "sha512-USm05zrsFxYLPdWWq+K3STlWiT/3ELn3RcV5hJMghpeAIhxfsUIg6mt12CBJBInWMV4VneoV7SfGv8xIwo2qNQ==", 862 | "dev": true, 863 | "license": "MIT", 864 | "dependencies": { 865 | "@types/estree": "^1.0.0", 866 | "estree-walker": "^2.0.2", 867 | "picomatch": "^4.0.2" 868 | }, 869 | "engines": { 870 | "node": ">=14.0.0" 871 | }, 872 | "peerDependencies": { 873 | "rollup": "^1.20.0||^2.0.0||^3.0.0||^4.0.0" 874 | }, 875 | "peerDependenciesMeta": { 876 | "rollup": { 877 | "optional": true 878 | } 879 | } 880 | }, 881 | "node_modules/@rollup/rollup-android-arm-eabi": { 882 | "version": "4.40.0", 883 | "resolved": "https://registry.npmjs.org/@rollup/rollup-android-arm-eabi/-/rollup-android-arm-eabi-4.40.0.tgz", 884 | "integrity": "sha512-+Fbls/diZ0RDerhE8kyC6hjADCXA1K4yVNlH0EYfd2XjyH0UGgzaQ8MlT0pCXAThfxv3QUAczHaL+qSv1E4/Cg==", 885 | "cpu": [ 886 | "arm" 887 | ], 888 | "dev": true, 889 | "license": "MIT", 890 | "optional": true, 891 | "os": [ 892 | "android" 893 | ] 894 | }, 895 | "node_modules/@rollup/rollup-android-arm64": { 896 | "version": "4.40.0", 897 | "resolved": "https://registry.npmjs.org/@rollup/rollup-android-arm64/-/rollup-android-arm64-4.40.0.tgz", 898 | "integrity": "sha512-PPA6aEEsTPRz+/4xxAmaoWDqh67N7wFbgFUJGMnanCFs0TV99M0M8QhhaSCks+n6EbQoFvLQgYOGXxlMGQe/6w==", 899 | "cpu": [ 900 | "arm64" 901 | ], 902 | "dev": true, 903 | "license": "MIT", 904 | "optional": true, 905 | "os": [ 906 | "android" 907 | ] 908 | }, 909 | "node_modules/@rollup/rollup-darwin-arm64": { 910 | "version": "4.40.0", 911 | "resolved": "https://registry.npmjs.org/@rollup/rollup-darwin-arm64/-/rollup-darwin-arm64-4.40.0.tgz", 912 | "integrity": "sha512-GwYOcOakYHdfnjjKwqpTGgn5a6cUX7+Ra2HeNj/GdXvO2VJOOXCiYYlRFU4CubFM67EhbmzLOmACKEfvp3J1kQ==", 913 | "cpu": [ 914 | "arm64" 915 | ], 916 | "dev": true, 917 | "license": "MIT", 918 | "optional": true, 919 | "os": [ 920 | "darwin" 921 | ] 922 | }, 923 | "node_modules/@rollup/rollup-darwin-x64": { 924 | "version": "4.40.0", 925 | "resolved": "https://registry.npmjs.org/@rollup/rollup-darwin-x64/-/rollup-darwin-x64-4.40.0.tgz", 926 | "integrity": "sha512-CoLEGJ+2eheqD9KBSxmma6ld01czS52Iw0e2qMZNpPDlf7Z9mj8xmMemxEucinev4LgHalDPczMyxzbq+Q+EtA==", 927 | "cpu": [ 928 | "x64" 929 | ], 930 | "dev": true, 931 | "license": "MIT", 932 | "optional": true, 933 | "os": [ 934 | "darwin" 935 | ] 936 | }, 937 | "node_modules/@rollup/rollup-freebsd-arm64": { 938 | "version": "4.40.0", 939 | "resolved": "https://registry.npmjs.org/@rollup/rollup-freebsd-arm64/-/rollup-freebsd-arm64-4.40.0.tgz", 940 | "integrity": "sha512-r7yGiS4HN/kibvESzmrOB/PxKMhPTlz+FcGvoUIKYoTyGd5toHp48g1uZy1o1xQvybwwpqpe010JrcGG2s5nkg==", 941 | "cpu": [ 942 | "arm64" 943 | ], 944 | "dev": true, 945 | "license": "MIT", 946 | "optional": true, 947 | "os": [ 948 | "freebsd" 949 | ] 950 | }, 951 | "node_modules/@rollup/rollup-freebsd-x64": { 952 | "version": "4.40.0", 953 | "resolved": "https://registry.npmjs.org/@rollup/rollup-freebsd-x64/-/rollup-freebsd-x64-4.40.0.tgz", 954 | "integrity": "sha512-mVDxzlf0oLzV3oZOr0SMJ0lSDd3xC4CmnWJ8Val8isp9jRGl5Dq//LLDSPFrasS7pSm6m5xAcKaw3sHXhBjoRw==", 955 | "cpu": [ 956 | "x64" 957 | ], 958 | "dev": true, 959 | "license": "MIT", 960 | "optional": true, 961 | "os": [ 962 | "freebsd" 963 | ] 964 | }, 965 | "node_modules/@rollup/rollup-linux-arm-gnueabihf": { 966 | "version": "4.40.0", 967 | "resolved": "https://registry.npmjs.org/@rollup/rollup-linux-arm-gnueabihf/-/rollup-linux-arm-gnueabihf-4.40.0.tgz", 968 | "integrity": "sha512-y/qUMOpJxBMy8xCXD++jeu8t7kzjlOCkoxxajL58G62PJGBZVl/Gwpm7JK9+YvlB701rcQTzjUZ1JgUoPTnoQA==", 969 | "cpu": [ 970 | "arm" 971 | ], 972 | "dev": true, 973 | "license": "MIT", 974 | "optional": true, 975 | "os": [ 976 | "linux" 977 | ] 978 | }, 979 | "node_modules/@rollup/rollup-linux-arm-musleabihf": { 980 | "version": "4.40.0", 981 | "resolved": "https://registry.npmjs.org/@rollup/rollup-linux-arm-musleabihf/-/rollup-linux-arm-musleabihf-4.40.0.tgz", 982 | "integrity": "sha512-GoCsPibtVdJFPv/BOIvBKO/XmwZLwaNWdyD8TKlXuqp0veo2sHE+A/vpMQ5iSArRUz/uaoj4h5S6Pn0+PdhRjg==", 983 | "cpu": [ 984 | "arm" 985 | ], 986 | "dev": true, 987 | "license": "MIT", 988 | "optional": true, 989 | "os": [ 990 | "linux" 991 | ] 992 | }, 993 | "node_modules/@rollup/rollup-linux-arm64-gnu": { 994 | "version": "4.40.0", 995 | "resolved": "https://registry.npmjs.org/@rollup/rollup-linux-arm64-gnu/-/rollup-linux-arm64-gnu-4.40.0.tgz", 996 | "integrity": "sha512-L5ZLphTjjAD9leJzSLI7rr8fNqJMlGDKlazW2tX4IUF9P7R5TMQPElpH82Q7eNIDQnQlAyiNVfRPfP2vM5Avvg==", 997 | "cpu": [ 998 | "arm64" 999 | ], 1000 | "dev": true, 1001 | "license": "MIT", 1002 | "optional": true, 1003 | "os": [ 1004 | "linux" 1005 | ] 1006 | }, 1007 | "node_modules/@rollup/rollup-linux-arm64-musl": { 1008 | "version": "4.40.0", 1009 | "resolved": "https://registry.npmjs.org/@rollup/rollup-linux-arm64-musl/-/rollup-linux-arm64-musl-4.40.0.tgz", 1010 | "integrity": "sha512-ATZvCRGCDtv1Y4gpDIXsS+wfFeFuLwVxyUBSLawjgXK2tRE6fnsQEkE4csQQYWlBlsFztRzCnBvWVfcae/1qxQ==", 1011 | "cpu": [ 1012 | "arm64" 1013 | ], 1014 | "dev": true, 1015 | "license": "MIT", 1016 | "optional": true, 1017 | "os": [ 1018 | "linux" 1019 | ] 1020 | }, 1021 | "node_modules/@rollup/rollup-linux-loongarch64-gnu": { 1022 | "version": "4.40.0", 1023 | "resolved": "https://registry.npmjs.org/@rollup/rollup-linux-loongarch64-gnu/-/rollup-linux-loongarch64-gnu-4.40.0.tgz", 1024 | "integrity": "sha512-wG9e2XtIhd++QugU5MD9i7OnpaVb08ji3P1y/hNbxrQ3sYEelKJOq1UJ5dXczeo6Hj2rfDEL5GdtkMSVLa/AOg==", 1025 | "cpu": [ 1026 | "loong64" 1027 | ], 1028 | "dev": true, 1029 | "license": "MIT", 1030 | "optional": true, 1031 | "os": [ 1032 | "linux" 1033 | ] 1034 | }, 1035 | "node_modules/@rollup/rollup-linux-powerpc64le-gnu": { 1036 | "version": "4.40.0", 1037 | "resolved": "https://registry.npmjs.org/@rollup/rollup-linux-powerpc64le-gnu/-/rollup-linux-powerpc64le-gnu-4.40.0.tgz", 1038 | "integrity": "sha512-vgXfWmj0f3jAUvC7TZSU/m/cOE558ILWDzS7jBhiCAFpY2WEBn5jqgbqvmzlMjtp8KlLcBlXVD2mkTSEQE6Ixw==", 1039 | "cpu": [ 1040 | "ppc64" 1041 | ], 1042 | "dev": true, 1043 | "license": "MIT", 1044 | "optional": true, 1045 | "os": [ 1046 | "linux" 1047 | ] 1048 | }, 1049 | "node_modules/@rollup/rollup-linux-riscv64-gnu": { 1050 | "version": "4.40.0", 1051 | "resolved": "https://registry.npmjs.org/@rollup/rollup-linux-riscv64-gnu/-/rollup-linux-riscv64-gnu-4.40.0.tgz", 1052 | "integrity": "sha512-uJkYTugqtPZBS3Z136arevt/FsKTF/J9dEMTX/cwR7lsAW4bShzI2R0pJVw+hcBTWF4dxVckYh72Hk3/hWNKvA==", 1053 | "cpu": [ 1054 | "riscv64" 1055 | ], 1056 | "dev": true, 1057 | "license": "MIT", 1058 | "optional": true, 1059 | "os": [ 1060 | "linux" 1061 | ] 1062 | }, 1063 | "node_modules/@rollup/rollup-linux-riscv64-musl": { 1064 | "version": "4.40.0", 1065 | "resolved": "https://registry.npmjs.org/@rollup/rollup-linux-riscv64-musl/-/rollup-linux-riscv64-musl-4.40.0.tgz", 1066 | "integrity": "sha512-rKmSj6EXQRnhSkE22+WvrqOqRtk733x3p5sWpZilhmjnkHkpeCgWsFFo0dGnUGeA+OZjRl3+VYq+HyCOEuwcxQ==", 1067 | "cpu": [ 1068 | "riscv64" 1069 | ], 1070 | "dev": true, 1071 | "license": "MIT", 1072 | "optional": true, 1073 | "os": [ 1074 | "linux" 1075 | ] 1076 | }, 1077 | "node_modules/@rollup/rollup-linux-s390x-gnu": { 1078 | "version": "4.40.0", 1079 | "resolved": "https://registry.npmjs.org/@rollup/rollup-linux-s390x-gnu/-/rollup-linux-s390x-gnu-4.40.0.tgz", 1080 | "integrity": "sha512-SpnYlAfKPOoVsQqmTFJ0usx0z84bzGOS9anAC0AZ3rdSo3snecihbhFTlJZ8XMwzqAcodjFU4+/SM311dqE5Sw==", 1081 | "cpu": [ 1082 | "s390x" 1083 | ], 1084 | "dev": true, 1085 | "license": "MIT", 1086 | "optional": true, 1087 | "os": [ 1088 | "linux" 1089 | ] 1090 | }, 1091 | "node_modules/@rollup/rollup-linux-x64-gnu": { 1092 | "version": "4.40.0", 1093 | "resolved": "https://registry.npmjs.org/@rollup/rollup-linux-x64-gnu/-/rollup-linux-x64-gnu-4.40.0.tgz", 1094 | "integrity": "sha512-RcDGMtqF9EFN8i2RYN2W+64CdHruJ5rPqrlYw+cgM3uOVPSsnAQps7cpjXe9be/yDp8UC7VLoCoKC8J3Kn2FkQ==", 1095 | "cpu": [ 1096 | "x64" 1097 | ], 1098 | "dev": true, 1099 | "license": "MIT", 1100 | "optional": true, 1101 | "os": [ 1102 | "linux" 1103 | ] 1104 | }, 1105 | "node_modules/@rollup/rollup-linux-x64-musl": { 1106 | "version": "4.40.0", 1107 | "resolved": "https://registry.npmjs.org/@rollup/rollup-linux-x64-musl/-/rollup-linux-x64-musl-4.40.0.tgz", 1108 | "integrity": "sha512-HZvjpiUmSNx5zFgwtQAV1GaGazT2RWvqeDi0hV+AtC8unqqDSsaFjPxfsO6qPtKRRg25SisACWnJ37Yio8ttaw==", 1109 | "cpu": [ 1110 | "x64" 1111 | ], 1112 | "dev": true, 1113 | "license": "MIT", 1114 | "optional": true, 1115 | "os": [ 1116 | "linux" 1117 | ] 1118 | }, 1119 | "node_modules/@rollup/rollup-win32-arm64-msvc": { 1120 | "version": "4.40.0", 1121 | "resolved": "https://registry.npmjs.org/@rollup/rollup-win32-arm64-msvc/-/rollup-win32-arm64-msvc-4.40.0.tgz", 1122 | "integrity": "sha512-UtZQQI5k/b8d7d3i9AZmA/t+Q4tk3hOC0tMOMSq2GlMYOfxbesxG4mJSeDp0EHs30N9bsfwUvs3zF4v/RzOeTQ==", 1123 | "cpu": [ 1124 | "arm64" 1125 | ], 1126 | "dev": true, 1127 | "license": "MIT", 1128 | "optional": true, 1129 | "os": [ 1130 | "win32" 1131 | ] 1132 | }, 1133 | "node_modules/@rollup/rollup-win32-ia32-msvc": { 1134 | "version": "4.40.0", 1135 | "resolved": "https://registry.npmjs.org/@rollup/rollup-win32-ia32-msvc/-/rollup-win32-ia32-msvc-4.40.0.tgz", 1136 | "integrity": "sha512-+m03kvI2f5syIqHXCZLPVYplP8pQch9JHyXKZ3AGMKlg8dCyr2PKHjwRLiW53LTrN/Nc3EqHOKxUxzoSPdKddA==", 1137 | "cpu": [ 1138 | "ia32" 1139 | ], 1140 | "dev": true, 1141 | "license": "MIT", 1142 | "optional": true, 1143 | "os": [ 1144 | "win32" 1145 | ] 1146 | }, 1147 | "node_modules/@rollup/rollup-win32-x64-msvc": { 1148 | "version": "4.40.0", 1149 | "resolved": "https://registry.npmjs.org/@rollup/rollup-win32-x64-msvc/-/rollup-win32-x64-msvc-4.40.0.tgz", 1150 | "integrity": "sha512-lpPE1cLfP5oPzVjKMx10pgBmKELQnFJXHgvtHCtuJWOv8MxqdEIMNtgHgBFf7Ea2/7EuVwa9fodWUfXAlXZLZQ==", 1151 | "cpu": [ 1152 | "x64" 1153 | ], 1154 | "dev": true, 1155 | "license": "MIT", 1156 | "optional": true, 1157 | "os": [ 1158 | "win32" 1159 | ] 1160 | }, 1161 | "node_modules/@types/estree": { 1162 | "version": "1.0.7", 1163 | "resolved": "https://registry.npmjs.org/@types/estree/-/estree-1.0.7.tgz", 1164 | "integrity": "sha512-w28IoSUCJpidD/TGviZwwMJckNESJZXFu7NBZ5YJ4mEUnNraUn9Pm8HSZm/jDF1pDWYKspWE7oVphigUPRakIQ==", 1165 | "dev": true, 1166 | "license": "MIT" 1167 | }, 1168 | "node_modules/@types/resolve": { 1169 | "version": "1.20.2", 1170 | "resolved": "https://registry.npmjs.org/@types/resolve/-/resolve-1.20.2.tgz", 1171 | "integrity": "sha512-60BCwRFOZCQhDncwQdxxeOEEkbc5dIMccYLwbxsS4TUNeVECQ/pBJ0j09mrHOl/JJvpRPGwO9SvE4nR2Nb/a4Q==", 1172 | "dev": true, 1173 | "license": "MIT" 1174 | }, 1175 | "node_modules/@typescript/analyze-trace": { 1176 | "version": "0.10.1", 1177 | "resolved": "https://registry.npmjs.org/@typescript/analyze-trace/-/analyze-trace-0.10.1.tgz", 1178 | "integrity": "sha512-RnlSOPh14QbopGCApgkSx5UBgGda5MX1cHqp2fsqfiDyCwGL/m1jaeB9fzu7didVS81LQqGZZuxFBcg8YU8EVw==", 1179 | "dev": true, 1180 | "license": "MIT", 1181 | "dependencies": { 1182 | "chalk": "^4.1.2", 1183 | "exit": "^0.1.2", 1184 | "jsonparse": "^1.3.1", 1185 | "jsonstream-next": "^3.0.0", 1186 | "p-limit": "^3.1.0", 1187 | "split2": "^3.2.2", 1188 | "treeify": "^1.1.0", 1189 | "yargs": "^16.2.0" 1190 | }, 1191 | "bin": { 1192 | "analyze-trace": "bin/analyze-trace", 1193 | "print-trace-types": "bin/print-trace-types", 1194 | "simplify-trace-types": "bin/simplify-trace-types" 1195 | } 1196 | }, 1197 | "node_modules/@typescript/vfs": { 1198 | "version": "1.6.1", 1199 | "resolved": "https://registry.npmjs.org/@typescript/vfs/-/vfs-1.6.1.tgz", 1200 | "integrity": "sha512-JwoxboBh7Oz1v38tPbkrZ62ZXNHAk9bJ7c9x0eI5zBfBnBYGhURdbnh7Z4smN/MV48Y5OCcZb58n972UtbazsA==", 1201 | "dev": true, 1202 | "license": "MIT", 1203 | "dependencies": { 1204 | "debug": "^4.1.1" 1205 | }, 1206 | "peerDependencies": { 1207 | "typescript": "*" 1208 | } 1209 | }, 1210 | "node_modules/@vitest/expect": { 1211 | "version": "3.1.2", 1212 | "resolved": "https://registry.npmjs.org/@vitest/expect/-/expect-3.1.2.tgz", 1213 | "integrity": "sha512-O8hJgr+zREopCAqWl3uCVaOdqJwZ9qaDwUP7vy3Xigad0phZe9APxKhPcDNqYYi0rX5oMvwJMSCAXY2afqeTSA==", 1214 | "dev": true, 1215 | "license": "MIT", 1216 | "dependencies": { 1217 | "@vitest/spy": "3.1.2", 1218 | "@vitest/utils": "3.1.2", 1219 | "chai": "^5.2.0", 1220 | "tinyrainbow": "^2.0.0" 1221 | }, 1222 | "funding": { 1223 | "url": "https://opencollective.com/vitest" 1224 | } 1225 | }, 1226 | "node_modules/@vitest/mocker": { 1227 | "version": "3.1.2", 1228 | "resolved": "https://registry.npmjs.org/@vitest/mocker/-/mocker-3.1.2.tgz", 1229 | "integrity": "sha512-kOtd6K2lc7SQ0mBqYv/wdGedlqPdM/B38paPY+OwJ1XiNi44w3Fpog82UfOibmHaV9Wod18A09I9SCKLyDMqgw==", 1230 | "dev": true, 1231 | "license": "MIT", 1232 | "dependencies": { 1233 | "@vitest/spy": "3.1.2", 1234 | "estree-walker": "^3.0.3", 1235 | "magic-string": "^0.30.17" 1236 | }, 1237 | "funding": { 1238 | "url": "https://opencollective.com/vitest" 1239 | }, 1240 | "peerDependencies": { 1241 | "msw": "^2.4.9", 1242 | "vite": "^5.0.0 || ^6.0.0" 1243 | }, 1244 | "peerDependenciesMeta": { 1245 | "msw": { 1246 | "optional": true 1247 | }, 1248 | "vite": { 1249 | "optional": true 1250 | } 1251 | } 1252 | }, 1253 | "node_modules/@vitest/mocker/node_modules/estree-walker": { 1254 | "version": "3.0.3", 1255 | "resolved": "https://registry.npmjs.org/estree-walker/-/estree-walker-3.0.3.tgz", 1256 | "integrity": "sha512-7RUKfXgSMMkzt6ZuXmqapOurLGPPfgj6l9uRZ7lRGolvk0y2yocc35LdcxKC5PQZdn2DMqioAQ2NoWcrTKmm6g==", 1257 | "dev": true, 1258 | "license": "MIT", 1259 | "dependencies": { 1260 | "@types/estree": "^1.0.0" 1261 | } 1262 | }, 1263 | "node_modules/@vitest/pretty-format": { 1264 | "version": "3.1.2", 1265 | "resolved": "https://registry.npmjs.org/@vitest/pretty-format/-/pretty-format-3.1.2.tgz", 1266 | "integrity": "sha512-R0xAiHuWeDjTSB3kQ3OQpT8Rx3yhdOAIm/JM4axXxnG7Q/fS8XUwggv/A4xzbQA+drYRjzkMnpYnOGAc4oeq8w==", 1267 | "dev": true, 1268 | "license": "MIT", 1269 | "dependencies": { 1270 | "tinyrainbow": "^2.0.0" 1271 | }, 1272 | "funding": { 1273 | "url": "https://opencollective.com/vitest" 1274 | } 1275 | }, 1276 | "node_modules/@vitest/runner": { 1277 | "version": "3.1.2", 1278 | "resolved": "https://registry.npmjs.org/@vitest/runner/-/runner-3.1.2.tgz", 1279 | "integrity": "sha512-bhLib9l4xb4sUMPXnThbnhX2Yi8OutBMA8Yahxa7yavQsFDtwY/jrUZwpKp2XH9DhRFJIeytlyGpXCqZ65nR+g==", 1280 | "dev": true, 1281 | "license": "MIT", 1282 | "dependencies": { 1283 | "@vitest/utils": "3.1.2", 1284 | "pathe": "^2.0.3" 1285 | }, 1286 | "funding": { 1287 | "url": "https://opencollective.com/vitest" 1288 | } 1289 | }, 1290 | "node_modules/@vitest/snapshot": { 1291 | "version": "3.1.2", 1292 | "resolved": "https://registry.npmjs.org/@vitest/snapshot/-/snapshot-3.1.2.tgz", 1293 | "integrity": "sha512-Q1qkpazSF/p4ApZg1vfZSQ5Yw6OCQxVMVrLjslbLFA1hMDrT2uxtqMaw8Tc/jy5DLka1sNs1Y7rBcftMiaSH/Q==", 1294 | "dev": true, 1295 | "license": "MIT", 1296 | "dependencies": { 1297 | "@vitest/pretty-format": "3.1.2", 1298 | "magic-string": "^0.30.17", 1299 | "pathe": "^2.0.3" 1300 | }, 1301 | "funding": { 1302 | "url": "https://opencollective.com/vitest" 1303 | } 1304 | }, 1305 | "node_modules/@vitest/spy": { 1306 | "version": "3.1.2", 1307 | "resolved": "https://registry.npmjs.org/@vitest/spy/-/spy-3.1.2.tgz", 1308 | "integrity": "sha512-OEc5fSXMws6sHVe4kOFyDSj/+4MSwst0ib4un0DlcYgQvRuYQ0+M2HyqGaauUMnjq87tmUaMNDxKQx7wNfVqPA==", 1309 | "dev": true, 1310 | "license": "MIT", 1311 | "dependencies": { 1312 | "tinyspy": "^3.0.2" 1313 | }, 1314 | "funding": { 1315 | "url": "https://opencollective.com/vitest" 1316 | } 1317 | }, 1318 | "node_modules/@vitest/utils": { 1319 | "version": "3.1.2", 1320 | "resolved": "https://registry.npmjs.org/@vitest/utils/-/utils-3.1.2.tgz", 1321 | "integrity": "sha512-5GGd0ytZ7BH3H6JTj9Kw7Prn1Nbg0wZVrIvou+UWxm54d+WoXXgAgjFJ8wn3LdagWLFSEfpPeyYrByZaGEZHLg==", 1322 | "dev": true, 1323 | "license": "MIT", 1324 | "dependencies": { 1325 | "@vitest/pretty-format": "3.1.2", 1326 | "loupe": "^3.1.3", 1327 | "tinyrainbow": "^2.0.0" 1328 | }, 1329 | "funding": { 1330 | "url": "https://opencollective.com/vitest" 1331 | } 1332 | }, 1333 | "node_modules/ansi-regex": { 1334 | "version": "5.0.1", 1335 | "resolved": "https://registry.npmjs.org/ansi-regex/-/ansi-regex-5.0.1.tgz", 1336 | "integrity": "sha512-quJQXlTSUGL2LH9SUXo8VwsY4soanhgo6LNSm84E1LBcE8s3O0wpdiRzyR9z/ZZJMlMWv37qOOb9pdJlMUEKFQ==", 1337 | "dev": true, 1338 | "license": "MIT", 1339 | "engines": { 1340 | "node": ">=8" 1341 | } 1342 | }, 1343 | "node_modules/ansi-styles": { 1344 | "version": "4.3.0", 1345 | "resolved": "https://registry.npmjs.org/ansi-styles/-/ansi-styles-4.3.0.tgz", 1346 | "integrity": "sha512-zbB9rCJAT1rbjiVDb2hqKFHNYLxgtk8NURxZ3IZwD3F6NtxbXZQCnnSi1Lkx+IDohdPlFp222wVALIheZJQSEg==", 1347 | "dev": true, 1348 | "license": "MIT", 1349 | "dependencies": { 1350 | "color-convert": "^2.0.1" 1351 | }, 1352 | "engines": { 1353 | "node": ">=8" 1354 | }, 1355 | "funding": { 1356 | "url": "https://github.com/chalk/ansi-styles?sponsor=1" 1357 | } 1358 | }, 1359 | "node_modules/arktype": { 1360 | "version": "2.1.20", 1361 | "resolved": "https://registry.npmjs.org/arktype/-/arktype-2.1.20.tgz", 1362 | "integrity": "sha512-IZCEEXaJ8g+Ijd59WtSYwtjnqXiwM8sWQ5EjGamcto7+HVN9eK0C4p0zDlCuAwWhpqr6fIBkxPuYDl4/Mcj/+Q==", 1363 | "dev": true, 1364 | "license": "MIT", 1365 | "dependencies": { 1366 | "@ark/schema": "0.46.0", 1367 | "@ark/util": "0.46.0" 1368 | } 1369 | }, 1370 | "node_modules/assertion-error": { 1371 | "version": "2.0.1", 1372 | "resolved": "https://registry.npmjs.org/assertion-error/-/assertion-error-2.0.1.tgz", 1373 | "integrity": "sha512-Izi8RQcffqCeNVgFigKli1ssklIbpHnCYc6AknXGYoB6grJqyeby7jv12JUQgmTAnIDnbck1uxksT4dzN3PWBA==", 1374 | "dev": true, 1375 | "license": "MIT", 1376 | "engines": { 1377 | "node": ">=12" 1378 | } 1379 | }, 1380 | "node_modules/astring": { 1381 | "version": "1.9.0", 1382 | "resolved": "https://registry.npmjs.org/astring/-/astring-1.9.0.tgz", 1383 | "integrity": "sha512-LElXdjswlqjWrPpJFg1Fx4wpkOCxj1TDHlSV4PlaRxHGWko024xICaa97ZkMfs6DRKlCguiAI+rbXv5GWwXIkg==", 1384 | "dev": true, 1385 | "license": "MIT", 1386 | "bin": { 1387 | "astring": "bin/astring" 1388 | } 1389 | }, 1390 | "node_modules/braces": { 1391 | "version": "3.0.3", 1392 | "resolved": "https://registry.npmjs.org/braces/-/braces-3.0.3.tgz", 1393 | "integrity": "sha512-yQbXgO/OSZVD2IsiLlro+7Hf6Q18EJrKSEsdoMzKePKXct3gvD8oLcOQdIzGupr5Fj+EDe8gO/lxc1BzfMpxvA==", 1394 | "dev": true, 1395 | "license": "MIT", 1396 | "dependencies": { 1397 | "fill-range": "^7.1.1" 1398 | }, 1399 | "engines": { 1400 | "node": ">=8" 1401 | } 1402 | }, 1403 | "node_modules/cac": { 1404 | "version": "6.7.14", 1405 | "resolved": "https://registry.npmjs.org/cac/-/cac-6.7.14.tgz", 1406 | "integrity": "sha512-b6Ilus+c3RrdDk+JhLKUAQfzzgLEPy6wcXqS7f/xe1EETvsDP6GORG7SFuOs6cID5YkqchW/LXZbX5bc8j7ZcQ==", 1407 | "dev": true, 1408 | "license": "MIT", 1409 | "engines": { 1410 | "node": ">=8" 1411 | } 1412 | }, 1413 | "node_modules/chai": { 1414 | "version": "5.2.0", 1415 | "resolved": "https://registry.npmjs.org/chai/-/chai-5.2.0.tgz", 1416 | "integrity": "sha512-mCuXncKXk5iCLhfhwTc0izo0gtEmpz5CtG2y8GiOINBlMVS6v8TMRc5TaLWKS6692m9+dVVfzgeVxR5UxWHTYw==", 1417 | "dev": true, 1418 | "license": "MIT", 1419 | "dependencies": { 1420 | "assertion-error": "^2.0.1", 1421 | "check-error": "^2.1.1", 1422 | "deep-eql": "^5.0.1", 1423 | "loupe": "^3.1.0", 1424 | "pathval": "^2.0.0" 1425 | }, 1426 | "engines": { 1427 | "node": ">=12" 1428 | } 1429 | }, 1430 | "node_modules/chalk": { 1431 | "version": "4.1.2", 1432 | "resolved": "https://registry.npmjs.org/chalk/-/chalk-4.1.2.tgz", 1433 | "integrity": "sha512-oKnbhFyRIXpUuez8iBMmyEa4nbj4IOQyuhc/wy9kY7/WVPcwIO9VA668Pu8RkO7+0G76SLROeyw9CpQ061i4mA==", 1434 | "dev": true, 1435 | "license": "MIT", 1436 | "dependencies": { 1437 | "ansi-styles": "^4.1.0", 1438 | "supports-color": "^7.1.0" 1439 | }, 1440 | "engines": { 1441 | "node": ">=10" 1442 | }, 1443 | "funding": { 1444 | "url": "https://github.com/chalk/chalk?sponsor=1" 1445 | } 1446 | }, 1447 | "node_modules/check-error": { 1448 | "version": "2.1.1", 1449 | "resolved": "https://registry.npmjs.org/check-error/-/check-error-2.1.1.tgz", 1450 | "integrity": "sha512-OAlb+T7V4Op9OwdkjmguYRqncdlx5JiofwOAUkmTF+jNdHwzTaTs4sRAGpzLF3oOz5xAyDGrPgeIDFQmDOTiJw==", 1451 | "dev": true, 1452 | "license": "MIT", 1453 | "engines": { 1454 | "node": ">= 16" 1455 | } 1456 | }, 1457 | "node_modules/cliui": { 1458 | "version": "7.0.4", 1459 | "resolved": "https://registry.npmjs.org/cliui/-/cliui-7.0.4.tgz", 1460 | "integrity": "sha512-OcRE68cOsVMXp1Yvonl/fzkQOyjLSu/8bhPDfQt0e0/Eb283TKP20Fs2MqoPsr9SwA595rRCA+QMzYc9nBP+JQ==", 1461 | "dev": true, 1462 | "license": "ISC", 1463 | "dependencies": { 1464 | "string-width": "^4.2.0", 1465 | "strip-ansi": "^6.0.0", 1466 | "wrap-ansi": "^7.0.0" 1467 | } 1468 | }, 1469 | "node_modules/color-convert": { 1470 | "version": "2.0.1", 1471 | "resolved": "https://registry.npmjs.org/color-convert/-/color-convert-2.0.1.tgz", 1472 | "integrity": "sha512-RRECPsj7iu/xb5oKYcsFHSppFNnsj/52OVTRKb4zP5onXwVF3zVmmToNcOfGC+CRDpfK/U584fMg38ZHCaElKQ==", 1473 | "dev": true, 1474 | "license": "MIT", 1475 | "dependencies": { 1476 | "color-name": "~1.1.4" 1477 | }, 1478 | "engines": { 1479 | "node": ">=7.0.0" 1480 | } 1481 | }, 1482 | "node_modules/color-name": { 1483 | "version": "1.1.4", 1484 | "resolved": "https://registry.npmjs.org/color-name/-/color-name-1.1.4.tgz", 1485 | "integrity": "sha512-dOy+3AuW3a2wNbZHIuMZpTcgjGuLU/uBL/ubcZF9OXbDo8ff4O8yVp5Bf0efS8uEoYo5q4Fx7dY9OgQGXgAsQA==", 1486 | "dev": true, 1487 | "license": "MIT" 1488 | }, 1489 | "node_modules/commondir": { 1490 | "version": "1.0.1", 1491 | "resolved": "https://registry.npmjs.org/commondir/-/commondir-1.0.1.tgz", 1492 | "integrity": "sha512-W9pAhw0ja1Edb5GVdIF1mjZw/ASI0AlShXM83UUGe2DVr5TdAPEA1OA8m/g8zWp9x6On7gqufY+FatDbC3MDQg==", 1493 | "dev": true, 1494 | "license": "MIT" 1495 | }, 1496 | "node_modules/debug": { 1497 | "version": "4.4.0", 1498 | "resolved": "https://registry.npmjs.org/debug/-/debug-4.4.0.tgz", 1499 | "integrity": "sha512-6WTZ/IxCY/T6BALoZHaE4ctp9xm+Z5kY/pzYaCHRFeyVhojxlrm+46y68HA6hr0TcwEssoxNiDEUJQjfPZ/RYA==", 1500 | "dev": true, 1501 | "license": "MIT", 1502 | "dependencies": { 1503 | "ms": "^2.1.3" 1504 | }, 1505 | "engines": { 1506 | "node": ">=6.0" 1507 | }, 1508 | "peerDependenciesMeta": { 1509 | "supports-color": { 1510 | "optional": true 1511 | } 1512 | } 1513 | }, 1514 | "node_modules/deep-eql": { 1515 | "version": "5.0.2", 1516 | "resolved": "https://registry.npmjs.org/deep-eql/-/deep-eql-5.0.2.tgz", 1517 | "integrity": "sha512-h5k/5U50IJJFpzfL6nO9jaaumfjO/f2NjK/oYB2Djzm4p9L+3T9qWpZqZ2hAbLPuuYq9wrU08WQyBTL5GbPk5Q==", 1518 | "dev": true, 1519 | "license": "MIT", 1520 | "engines": { 1521 | "node": ">=6" 1522 | } 1523 | }, 1524 | "node_modules/deepmerge": { 1525 | "version": "4.3.1", 1526 | "resolved": "https://registry.npmjs.org/deepmerge/-/deepmerge-4.3.1.tgz", 1527 | "integrity": "sha512-3sUqbMEc77XqpdNO7FRyRog+eW3ph+GYCbj+rK+uYyRMuwsVy0rMiVtPn+QJlKFvWP/1PYpapqYn0Me2knFn+A==", 1528 | "dev": true, 1529 | "license": "MIT", 1530 | "engines": { 1531 | "node": ">=0.10.0" 1532 | } 1533 | }, 1534 | "node_modules/emoji-regex": { 1535 | "version": "8.0.0", 1536 | "resolved": "https://registry.npmjs.org/emoji-regex/-/emoji-regex-8.0.0.tgz", 1537 | "integrity": "sha512-MSjYzcWNOA0ewAHpz0MxpYFvwg6yjy1NG3xteoqz644VCo/RPgnr1/GGt+ic3iJTzQ8Eu3TdM14SawnVUmGE6A==", 1538 | "dev": true, 1539 | "license": "MIT" 1540 | }, 1541 | "node_modules/es-module-lexer": { 1542 | "version": "1.6.0", 1543 | "resolved": "https://registry.npmjs.org/es-module-lexer/-/es-module-lexer-1.6.0.tgz", 1544 | "integrity": "sha512-qqnD1yMU6tk/jnaMosogGySTZP8YtUgAffA9nMN+E/rjxcfRQ6IEk7IiozUjgxKoFHBGjTLnrHB/YC45r/59EQ==", 1545 | "dev": true, 1546 | "license": "MIT" 1547 | }, 1548 | "node_modules/esbuild": { 1549 | "version": "0.25.2", 1550 | "resolved": "https://registry.npmjs.org/esbuild/-/esbuild-0.25.2.tgz", 1551 | "integrity": "sha512-16854zccKPnC+toMywC+uKNeYSv+/eXkevRAfwRD/G9Cleq66m8XFIrigkbvauLLlCfDL45Q2cWegSg53gGBnQ==", 1552 | "dev": true, 1553 | "hasInstallScript": true, 1554 | "license": "MIT", 1555 | "bin": { 1556 | "esbuild": "bin/esbuild" 1557 | }, 1558 | "engines": { 1559 | "node": ">=18" 1560 | }, 1561 | "optionalDependencies": { 1562 | "@esbuild/aix-ppc64": "0.25.2", 1563 | "@esbuild/android-arm": "0.25.2", 1564 | "@esbuild/android-arm64": "0.25.2", 1565 | "@esbuild/android-x64": "0.25.2", 1566 | "@esbuild/darwin-arm64": "0.25.2", 1567 | "@esbuild/darwin-x64": "0.25.2", 1568 | "@esbuild/freebsd-arm64": "0.25.2", 1569 | "@esbuild/freebsd-x64": "0.25.2", 1570 | "@esbuild/linux-arm": "0.25.2", 1571 | "@esbuild/linux-arm64": "0.25.2", 1572 | "@esbuild/linux-ia32": "0.25.2", 1573 | "@esbuild/linux-loong64": "0.25.2", 1574 | "@esbuild/linux-mips64el": "0.25.2", 1575 | "@esbuild/linux-ppc64": "0.25.2", 1576 | "@esbuild/linux-riscv64": "0.25.2", 1577 | "@esbuild/linux-s390x": "0.25.2", 1578 | "@esbuild/linux-x64": "0.25.2", 1579 | "@esbuild/netbsd-arm64": "0.25.2", 1580 | "@esbuild/netbsd-x64": "0.25.2", 1581 | "@esbuild/openbsd-arm64": "0.25.2", 1582 | "@esbuild/openbsd-x64": "0.25.2", 1583 | "@esbuild/sunos-x64": "0.25.2", 1584 | "@esbuild/win32-arm64": "0.25.2", 1585 | "@esbuild/win32-ia32": "0.25.2", 1586 | "@esbuild/win32-x64": "0.25.2" 1587 | } 1588 | }, 1589 | "node_modules/escalade": { 1590 | "version": "3.2.0", 1591 | "resolved": "https://registry.npmjs.org/escalade/-/escalade-3.2.0.tgz", 1592 | "integrity": "sha512-WUj2qlxaQtO4g6Pq5c29GTcWGDyd8itL8zTlipgECz3JesAiiOKotd8JU6otB3PACgG6xkJUyVhboMS+bje/jA==", 1593 | "dev": true, 1594 | "license": "MIT", 1595 | "engines": { 1596 | "node": ">=6" 1597 | } 1598 | }, 1599 | "node_modules/estree-walker": { 1600 | "version": "2.0.2", 1601 | "resolved": "https://registry.npmjs.org/estree-walker/-/estree-walker-2.0.2.tgz", 1602 | "integrity": "sha512-Rfkk/Mp/DL7JVje3u18FxFujQlTNR2q6QfMSMB7AvCBx91NGj/ba3kCfza0f6dVDbw7YlRf/nDrn7pQrCCyQ/w==", 1603 | "dev": true, 1604 | "license": "MIT" 1605 | }, 1606 | "node_modules/exit": { 1607 | "version": "0.1.2", 1608 | "resolved": "https://registry.npmjs.org/exit/-/exit-0.1.2.tgz", 1609 | "integrity": "sha512-Zk/eNKV2zbjpKzrsQ+n1G6poVbErQxJ0LBOJXaKZ1EViLzH+hrLu9cdXI4zw9dBQJslwBEpbQ2P1oS7nDxs6jQ==", 1610 | "dev": true, 1611 | "engines": { 1612 | "node": ">= 0.8.0" 1613 | } 1614 | }, 1615 | "node_modules/expect-type": { 1616 | "version": "1.2.1", 1617 | "resolved": "https://registry.npmjs.org/expect-type/-/expect-type-1.2.1.tgz", 1618 | "integrity": "sha512-/kP8CAwxzLVEeFrMm4kMmy4CCDlpipyA7MYLVrdJIkV0fYF0UaigQHRsxHiuY/GEea+bh4KSv3TIlgr+2UL6bw==", 1619 | "dev": true, 1620 | "license": "Apache-2.0", 1621 | "engines": { 1622 | "node": ">=12.0.0" 1623 | } 1624 | }, 1625 | "node_modules/fast-glob": { 1626 | "version": "3.3.3", 1627 | "resolved": "https://registry.npmjs.org/fast-glob/-/fast-glob-3.3.3.tgz", 1628 | "integrity": "sha512-7MptL8U0cqcFdzIzwOTHoilX9x5BrNqye7Z/LuC7kCMRio1EMSyqRK3BEAUD7sXRq4iT4AzTVuZdhgQ2TCvYLg==", 1629 | "dev": true, 1630 | "license": "MIT", 1631 | "dependencies": { 1632 | "@nodelib/fs.stat": "^2.0.2", 1633 | "@nodelib/fs.walk": "^1.2.3", 1634 | "glob-parent": "^5.1.2", 1635 | "merge2": "^1.3.0", 1636 | "micromatch": "^4.0.8" 1637 | }, 1638 | "engines": { 1639 | "node": ">=8.6.0" 1640 | } 1641 | }, 1642 | "node_modules/fastq": { 1643 | "version": "1.19.1", 1644 | "resolved": "https://registry.npmjs.org/fastq/-/fastq-1.19.1.tgz", 1645 | "integrity": "sha512-GwLTyxkCXjXbxqIhTsMI2Nui8huMPtnxg7krajPJAjnEG/iiOS7i+zCtWGZR9G0NBKbXKh6X9m9UIsYX/N6vvQ==", 1646 | "dev": true, 1647 | "license": "ISC", 1648 | "dependencies": { 1649 | "reusify": "^1.0.4" 1650 | } 1651 | }, 1652 | "node_modules/fdir": { 1653 | "version": "6.4.4", 1654 | "resolved": "https://registry.npmjs.org/fdir/-/fdir-6.4.4.tgz", 1655 | "integrity": "sha512-1NZP+GK4GfuAv3PqKvxQRDMjdSRZjnkq7KfhlNrCNNlZ0ygQFpebfrnfnq/W7fpUnAv9aGWmY1zKx7FYL3gwhg==", 1656 | "dev": true, 1657 | "license": "MIT", 1658 | "peerDependencies": { 1659 | "picomatch": "^3 || ^4" 1660 | }, 1661 | "peerDependenciesMeta": { 1662 | "picomatch": { 1663 | "optional": true 1664 | } 1665 | } 1666 | }, 1667 | "node_modules/fill-range": { 1668 | "version": "7.1.1", 1669 | "resolved": "https://registry.npmjs.org/fill-range/-/fill-range-7.1.1.tgz", 1670 | "integrity": "sha512-YsGpe3WHLK8ZYi4tWDg2Jy3ebRz2rXowDxnld4bkQB00cc/1Zw9AWnC0i9ztDJitivtQvaI9KaLyKrc+hBW0yg==", 1671 | "dev": true, 1672 | "license": "MIT", 1673 | "dependencies": { 1674 | "to-regex-range": "^5.0.1" 1675 | }, 1676 | "engines": { 1677 | "node": ">=8" 1678 | } 1679 | }, 1680 | "node_modules/fsevents": { 1681 | "version": "2.3.3", 1682 | "resolved": "https://registry.npmjs.org/fsevents/-/fsevents-2.3.3.tgz", 1683 | "integrity": "sha512-5xoDfX+fL7faATnagmWPpbFtwh/R77WmMMqqHGS65C3vvB0YHrgF+B1YmZ3441tMj5n63k0212XNoJwzlhffQw==", 1684 | "dev": true, 1685 | "hasInstallScript": true, 1686 | "license": "MIT", 1687 | "optional": true, 1688 | "os": [ 1689 | "darwin" 1690 | ], 1691 | "engines": { 1692 | "node": "^8.16.0 || ^10.6.0 || >=11.0.0" 1693 | } 1694 | }, 1695 | "node_modules/function-bind": { 1696 | "version": "1.1.2", 1697 | "resolved": "https://registry.npmjs.org/function-bind/-/function-bind-1.1.2.tgz", 1698 | "integrity": "sha512-7XHNxH7qX9xG5mIwxkhumTox/MIRNcOgDrxWsMt2pAr23WHp6MrRlN7FBSFpCpr+oVO0F744iUgR82nJMfG2SA==", 1699 | "dev": true, 1700 | "license": "MIT", 1701 | "funding": { 1702 | "url": "https://github.com/sponsors/ljharb" 1703 | } 1704 | }, 1705 | "node_modules/get-caller-file": { 1706 | "version": "2.0.5", 1707 | "resolved": "https://registry.npmjs.org/get-caller-file/-/get-caller-file-2.0.5.tgz", 1708 | "integrity": "sha512-DyFP3BM/3YHTQOCUL/w0OZHR0lpKeGrxotcHWcqNEdnltqFwXVfhEBQ94eIo34AfQpo0rGki4cyIiftY06h2Fg==", 1709 | "dev": true, 1710 | "license": "ISC", 1711 | "engines": { 1712 | "node": "6.* || 8.* || >= 10.*" 1713 | } 1714 | }, 1715 | "node_modules/get-tsconfig": { 1716 | "version": "4.10.0", 1717 | "resolved": "https://registry.npmjs.org/get-tsconfig/-/get-tsconfig-4.10.0.tgz", 1718 | "integrity": "sha512-kGzZ3LWWQcGIAmg6iWvXn0ei6WDtV26wzHRMwDSzmAbcXrTEXxHy6IehI6/4eT6VRKyMP1eF1VqwrVUmE/LR7A==", 1719 | "dev": true, 1720 | "license": "MIT", 1721 | "dependencies": { 1722 | "resolve-pkg-maps": "^1.0.0" 1723 | }, 1724 | "funding": { 1725 | "url": "https://github.com/privatenumber/get-tsconfig?sponsor=1" 1726 | } 1727 | }, 1728 | "node_modules/glob-parent": { 1729 | "version": "5.1.2", 1730 | "resolved": "https://registry.npmjs.org/glob-parent/-/glob-parent-5.1.2.tgz", 1731 | "integrity": "sha512-AOIgSQCepiJYwP3ARnGx+5VnTu2HBYdzbGP45eLw1vr3zB3vZLeyed1sC9hnbcOc9/SrMyM5RPQrkGz4aS9Zow==", 1732 | "dev": true, 1733 | "license": "ISC", 1734 | "dependencies": { 1735 | "is-glob": "^4.0.1" 1736 | }, 1737 | "engines": { 1738 | "node": ">= 6" 1739 | } 1740 | }, 1741 | "node_modules/has-flag": { 1742 | "version": "4.0.0", 1743 | "resolved": "https://registry.npmjs.org/has-flag/-/has-flag-4.0.0.tgz", 1744 | "integrity": "sha512-EykJT/Q1KjTWctppgIAgfSO0tKVuZUjhgMr17kqTumMl6Afv3EISleU7qZUzoXDFTAHTDC4NOoG/ZxU3EvlMPQ==", 1745 | "dev": true, 1746 | "license": "MIT", 1747 | "engines": { 1748 | "node": ">=8" 1749 | } 1750 | }, 1751 | "node_modules/hasown": { 1752 | "version": "2.0.2", 1753 | "resolved": "https://registry.npmjs.org/hasown/-/hasown-2.0.2.tgz", 1754 | "integrity": "sha512-0hJU9SCPvmMzIBdZFqNPXWa6dqh7WdH0cII9y+CyS8rG3nL48Bclra9HmKhVVUHyPWNH5Y7xDwAB7bfgSjkUMQ==", 1755 | "dev": true, 1756 | "license": "MIT", 1757 | "dependencies": { 1758 | "function-bind": "^1.1.2" 1759 | }, 1760 | "engines": { 1761 | "node": ">= 0.4" 1762 | } 1763 | }, 1764 | "node_modules/inherits": { 1765 | "version": "2.0.4", 1766 | "resolved": "https://registry.npmjs.org/inherits/-/inherits-2.0.4.tgz", 1767 | "integrity": "sha512-k/vGaX4/Yla3WzyMCvTQOXYeIHvqOKtnqBduzTHpzpQZzAskKMhZ2K+EnBiSM9zGSoIFeMpXKxa4dYeZIQqewQ==", 1768 | "dev": true, 1769 | "license": "ISC" 1770 | }, 1771 | "node_modules/is-core-module": { 1772 | "version": "2.16.1", 1773 | "resolved": "https://registry.npmjs.org/is-core-module/-/is-core-module-2.16.1.tgz", 1774 | "integrity": "sha512-UfoeMA6fIJ8wTYFEUjelnaGI67v6+N7qXJEvQuIGa99l4xsCruSYOVSQ0uPANn4dAzm8lkYPaKLrrijLq7x23w==", 1775 | "dev": true, 1776 | "license": "MIT", 1777 | "dependencies": { 1778 | "hasown": "^2.0.2" 1779 | }, 1780 | "engines": { 1781 | "node": ">= 0.4" 1782 | }, 1783 | "funding": { 1784 | "url": "https://github.com/sponsors/ljharb" 1785 | } 1786 | }, 1787 | "node_modules/is-extglob": { 1788 | "version": "2.1.1", 1789 | "resolved": "https://registry.npmjs.org/is-extglob/-/is-extglob-2.1.1.tgz", 1790 | "integrity": "sha512-SbKbANkN603Vi4jEZv49LeVJMn4yGwsbzZworEoyEiutsN3nJYdbO36zfhGJ6QEDpOZIFkDtnq5JRxmvl3jsoQ==", 1791 | "dev": true, 1792 | "license": "MIT", 1793 | "engines": { 1794 | "node": ">=0.10.0" 1795 | } 1796 | }, 1797 | "node_modules/is-fullwidth-code-point": { 1798 | "version": "3.0.0", 1799 | "resolved": "https://registry.npmjs.org/is-fullwidth-code-point/-/is-fullwidth-code-point-3.0.0.tgz", 1800 | "integrity": "sha512-zymm5+u+sCsSWyD9qNaejV3DFvhCKclKdizYaJUuHA83RLjb7nSuGnddCHGv0hk+KY7BMAlsWeK4Ueg6EV6XQg==", 1801 | "dev": true, 1802 | "license": "MIT", 1803 | "engines": { 1804 | "node": ">=8" 1805 | } 1806 | }, 1807 | "node_modules/is-glob": { 1808 | "version": "4.0.3", 1809 | "resolved": "https://registry.npmjs.org/is-glob/-/is-glob-4.0.3.tgz", 1810 | "integrity": "sha512-xelSayHH36ZgE7ZWhli7pW34hNbNl8Ojv5KVmkJD4hBdD3th8Tfk9vYasLM+mXWOZhFkgZfxhLSnrwRr4elSSg==", 1811 | "dev": true, 1812 | "license": "MIT", 1813 | "dependencies": { 1814 | "is-extglob": "^2.1.1" 1815 | }, 1816 | "engines": { 1817 | "node": ">=0.10.0" 1818 | } 1819 | }, 1820 | "node_modules/is-module": { 1821 | "version": "1.0.0", 1822 | "resolved": "https://registry.npmjs.org/is-module/-/is-module-1.0.0.tgz", 1823 | "integrity": "sha512-51ypPSPCoTEIN9dy5Oy+h4pShgJmPCygKfyRCISBI+JoWT/2oJvK8QPxmwv7b/p239jXrm9M1mlQbyKJ5A152g==", 1824 | "dev": true, 1825 | "license": "MIT" 1826 | }, 1827 | "node_modules/is-number": { 1828 | "version": "7.0.0", 1829 | "resolved": "https://registry.npmjs.org/is-number/-/is-number-7.0.0.tgz", 1830 | "integrity": "sha512-41Cifkg6e8TylSpdtTpeLVMqvSBEVzTttHvERD741+pnZ8ANv0004MRL43QKPDlK9cGvNp6NZWZUBlbGXYxxng==", 1831 | "dev": true, 1832 | "license": "MIT", 1833 | "engines": { 1834 | "node": ">=0.12.0" 1835 | } 1836 | }, 1837 | "node_modules/is-reference": { 1838 | "version": "1.2.1", 1839 | "resolved": "https://registry.npmjs.org/is-reference/-/is-reference-1.2.1.tgz", 1840 | "integrity": "sha512-U82MsXXiFIrjCK4otLT+o2NA2Cd2g5MLoOVXUZjIOhLurrRxpEXzI8O0KZHr3IjLvlAH1kTPYSuqer5T9ZVBKQ==", 1841 | "dev": true, 1842 | "license": "MIT", 1843 | "dependencies": { 1844 | "@types/estree": "*" 1845 | } 1846 | }, 1847 | "node_modules/jsonparse": { 1848 | "version": "1.3.1", 1849 | "resolved": "https://registry.npmjs.org/jsonparse/-/jsonparse-1.3.1.tgz", 1850 | "integrity": "sha512-POQXvpdL69+CluYsillJ7SUhKvytYjW9vG/GKpnf+xP8UWgYEM/RaMzHHofbALDiKbbP1W8UEYmgGl39WkPZsg==", 1851 | "dev": true, 1852 | "engines": [ 1853 | "node >= 0.2.0" 1854 | ], 1855 | "license": "MIT" 1856 | }, 1857 | "node_modules/jsonstream-next": { 1858 | "version": "3.0.0", 1859 | "resolved": "https://registry.npmjs.org/jsonstream-next/-/jsonstream-next-3.0.0.tgz", 1860 | "integrity": "sha512-aAi6oPhdt7BKyQn1SrIIGZBt0ukKuOUE1qV6kJ3GgioSOYzsRc8z9Hfr1BVmacA/jLe9nARfmgMGgn68BqIAgg==", 1861 | "dev": true, 1862 | "license": "(MIT OR Apache-2.0)", 1863 | "dependencies": { 1864 | "jsonparse": "^1.2.0", 1865 | "through2": "^4.0.2" 1866 | }, 1867 | "bin": { 1868 | "jsonstream-next": "bin.js" 1869 | }, 1870 | "engines": { 1871 | "node": ">=10" 1872 | } 1873 | }, 1874 | "node_modules/loupe": { 1875 | "version": "3.1.3", 1876 | "resolved": "https://registry.npmjs.org/loupe/-/loupe-3.1.3.tgz", 1877 | "integrity": "sha512-kkIp7XSkP78ZxJEsSxW3712C6teJVoeHHwgo9zJ380de7IYyJ2ISlxojcH2pC5OFLewESmnRi/+XCDIEEVyoug==", 1878 | "dev": true, 1879 | "license": "MIT" 1880 | }, 1881 | "node_modules/magic-string": { 1882 | "version": "0.30.17", 1883 | "resolved": "https://registry.npmjs.org/magic-string/-/magic-string-0.30.17.tgz", 1884 | "integrity": "sha512-sNPKHvyjVf7gyjwS4xGTaW/mCnF8wnjtifKBEhxfZ7E/S8tQ0rssrwGNn6q8JH/ohItJfSQp9mBtQYuTlH5QnA==", 1885 | "dev": true, 1886 | "license": "MIT", 1887 | "dependencies": { 1888 | "@jridgewell/sourcemap-codec": "^1.5.0" 1889 | } 1890 | }, 1891 | "node_modules/make-synchronized": { 1892 | "version": "0.4.2", 1893 | "resolved": "https://registry.npmjs.org/make-synchronized/-/make-synchronized-0.4.2.tgz", 1894 | "integrity": "sha512-EwEJSg8gSGLicKXp/VzNi1tvzhdmNBxOzslkkJSoNUCQFZKH/NIUIp7xlfN+noaHrz4BJDN73gne8IHnjl/F/A==", 1895 | "dev": true, 1896 | "license": "MIT", 1897 | "funding": { 1898 | "url": "https://github.com/fisker/make-synchronized?sponsor=1" 1899 | } 1900 | }, 1901 | "node_modules/merge2": { 1902 | "version": "1.4.1", 1903 | "resolved": "https://registry.npmjs.org/merge2/-/merge2-1.4.1.tgz", 1904 | "integrity": "sha512-8q7VEgMJW4J8tcfVPy8g09NcQwZdbwFEqhe/WZkoIzjn/3TGDwtOCYtXGxA3O8tPzpczCCDgv+P2P5y00ZJOOg==", 1905 | "dev": true, 1906 | "license": "MIT", 1907 | "engines": { 1908 | "node": ">= 8" 1909 | } 1910 | }, 1911 | "node_modules/micromatch": { 1912 | "version": "4.0.8", 1913 | "resolved": "https://registry.npmjs.org/micromatch/-/micromatch-4.0.8.tgz", 1914 | "integrity": "sha512-PXwfBhYu0hBCPw8Dn0E+WDYb7af3dSLVWKi3HGv84IdF4TyFoC0ysxFd0Goxw7nSv4T/PzEJQxsYsEiFCKo2BA==", 1915 | "dev": true, 1916 | "license": "MIT", 1917 | "dependencies": { 1918 | "braces": "^3.0.3", 1919 | "picomatch": "^2.3.1" 1920 | }, 1921 | "engines": { 1922 | "node": ">=8.6" 1923 | } 1924 | }, 1925 | "node_modules/micromatch/node_modules/picomatch": { 1926 | "version": "2.3.1", 1927 | "resolved": "https://registry.npmjs.org/picomatch/-/picomatch-2.3.1.tgz", 1928 | "integrity": "sha512-JU3teHTNjmE2VCGFzuY8EXzCDVwEqB2a8fsIvwaStHhAWJEeVd1o1QD80CU6+ZdEXXSLbSsuLwJjkCBWqRQUVA==", 1929 | "dev": true, 1930 | "license": "MIT", 1931 | "engines": { 1932 | "node": ">=8.6" 1933 | }, 1934 | "funding": { 1935 | "url": "https://github.com/sponsors/jonschlinkert" 1936 | } 1937 | }, 1938 | "node_modules/ms": { 1939 | "version": "2.1.3", 1940 | "resolved": "https://registry.npmjs.org/ms/-/ms-2.1.3.tgz", 1941 | "integrity": "sha512-6FlzubTLZG3J2a/NVCAleEhjzq5oxgHyaCU9yYXvcLsvoVaHJq/s5xXI6/XXP6tz7R9xAOtHnSO/tXtF3WRTlA==", 1942 | "dev": true, 1943 | "license": "MIT" 1944 | }, 1945 | "node_modules/nanoid": { 1946 | "version": "3.3.11", 1947 | "resolved": "https://registry.npmjs.org/nanoid/-/nanoid-3.3.11.tgz", 1948 | "integrity": "sha512-N8SpfPUnUp1bK+PMYW8qSWdl9U+wwNWI4QKxOYDy9JAro3WMX7p2OeVRF9v+347pnakNevPmiHhNmZ2HbFA76w==", 1949 | "dev": true, 1950 | "funding": [ 1951 | { 1952 | "type": "github", 1953 | "url": "https://github.com/sponsors/ai" 1954 | } 1955 | ], 1956 | "license": "MIT", 1957 | "bin": { 1958 | "nanoid": "bin/nanoid.cjs" 1959 | }, 1960 | "engines": { 1961 | "node": "^10 || ^12 || ^13.7 || ^14 || >=15.0.1" 1962 | } 1963 | }, 1964 | "node_modules/p-limit": { 1965 | "version": "3.1.0", 1966 | "resolved": "https://registry.npmjs.org/p-limit/-/p-limit-3.1.0.tgz", 1967 | "integrity": "sha512-TYOanM3wGwNGsZN2cVTYPArw454xnXj5qmWF1bEoAc4+cU/ol7GVh7odevjp1FNHduHc3KZMcFduxU5Xc6uJRQ==", 1968 | "dev": true, 1969 | "license": "MIT", 1970 | "dependencies": { 1971 | "yocto-queue": "^0.1.0" 1972 | }, 1973 | "engines": { 1974 | "node": ">=10" 1975 | }, 1976 | "funding": { 1977 | "url": "https://github.com/sponsors/sindresorhus" 1978 | } 1979 | }, 1980 | "node_modules/path-parse": { 1981 | "version": "1.0.7", 1982 | "resolved": "https://registry.npmjs.org/path-parse/-/path-parse-1.0.7.tgz", 1983 | "integrity": "sha512-LDJzPVEEEPR+y48z93A0Ed0yXb8pAByGWo/k5YYdYgpY2/2EsOsksJrq7lOHxryrVOn1ejG6oAp8ahvOIQD8sw==", 1984 | "dev": true, 1985 | "license": "MIT" 1986 | }, 1987 | "node_modules/pathe": { 1988 | "version": "2.0.3", 1989 | "resolved": "https://registry.npmjs.org/pathe/-/pathe-2.0.3.tgz", 1990 | "integrity": "sha512-WUjGcAqP1gQacoQe+OBJsFA7Ld4DyXuUIjZ5cc75cLHvJ7dtNsTugphxIADwspS+AraAUePCKrSVtPLFj/F88w==", 1991 | "dev": true, 1992 | "license": "MIT" 1993 | }, 1994 | "node_modules/pathval": { 1995 | "version": "2.0.0", 1996 | "resolved": "https://registry.npmjs.org/pathval/-/pathval-2.0.0.tgz", 1997 | "integrity": "sha512-vE7JKRyES09KiunauX7nd2Q9/L7lhok4smP9RZTDeD4MVs72Dp2qNFVz39Nz5a0FVEW0BJR6C0DYrq6unoziZA==", 1998 | "dev": true, 1999 | "license": "MIT", 2000 | "engines": { 2001 | "node": ">= 14.16" 2002 | } 2003 | }, 2004 | "node_modules/picocolors": { 2005 | "version": "1.1.1", 2006 | "resolved": "https://registry.npmjs.org/picocolors/-/picocolors-1.1.1.tgz", 2007 | "integrity": "sha512-xceH2snhtb5M9liqDsmEw56le376mTZkEX/jEb/RxNFyegNul7eNslCXP9FDj/Lcu0X8KEyMceP2ntpaHrDEVA==", 2008 | "dev": true, 2009 | "license": "ISC" 2010 | }, 2011 | "node_modules/picomatch": { 2012 | "version": "4.0.2", 2013 | "resolved": "https://registry.npmjs.org/picomatch/-/picomatch-4.0.2.tgz", 2014 | "integrity": "sha512-M7BAV6Rlcy5u+m6oPhAPFgJTzAioX/6B0DxyvDlo9l8+T3nLKbrczg2WLUyzd45L8RqfUMyGPzekbMvX2Ldkwg==", 2015 | "dev": true, 2016 | "license": "MIT", 2017 | "engines": { 2018 | "node": ">=12" 2019 | }, 2020 | "funding": { 2021 | "url": "https://github.com/sponsors/jonschlinkert" 2022 | } 2023 | }, 2024 | "node_modules/pkgroll": { 2025 | "version": "2.12.1", 2026 | "resolved": "https://registry.npmjs.org/pkgroll/-/pkgroll-2.12.1.tgz", 2027 | "integrity": "sha512-MpooedkVk28Sl1I5q8YO2QZmdlHdEtCzv1nReZdHNRhY0CzbZ14TewN47JopF+0rGCaQOERSPfcIOgPZDQXlZA==", 2028 | "dev": true, 2029 | "license": "MIT", 2030 | "dependencies": { 2031 | "@rollup/plugin-alias": "^5.1.1", 2032 | "@rollup/plugin-commonjs": "^28.0.2", 2033 | "@rollup/plugin-dynamic-import-vars": "^2.1.5", 2034 | "@rollup/plugin-inject": "^5.0.5", 2035 | "@rollup/plugin-json": "^6.1.0", 2036 | "@rollup/plugin-node-resolve": "^16.0.0", 2037 | "@rollup/pluginutils": "^5.1.4", 2038 | "esbuild": "^0.25.1", 2039 | "magic-string": "^0.30.17", 2040 | "rollup": "^4.34.6", 2041 | "rollup-pluginutils": "^2.8.2" 2042 | }, 2043 | "bin": { 2044 | "pkgroll": "dist/cli.mjs" 2045 | }, 2046 | "engines": { 2047 | "node": ">=18" 2048 | }, 2049 | "funding": { 2050 | "url": "https://github.com/privatenumber/pkgroll?sponsor=1" 2051 | }, 2052 | "peerDependencies": { 2053 | "typescript": "^4.1 || ^5.0" 2054 | }, 2055 | "peerDependenciesMeta": { 2056 | "typescript": { 2057 | "optional": true 2058 | } 2059 | } 2060 | }, 2061 | "node_modules/postcss": { 2062 | "version": "8.5.3", 2063 | "resolved": "https://registry.npmjs.org/postcss/-/postcss-8.5.3.tgz", 2064 | "integrity": "sha512-dle9A3yYxlBSrt8Fu+IpjGT8SY8hN0mlaA6GY8t0P5PjIOZemULz/E2Bnm/2dcUOena75OTNkHI76uZBNUUq3A==", 2065 | "dev": true, 2066 | "funding": [ 2067 | { 2068 | "type": "opencollective", 2069 | "url": "https://opencollective.com/postcss/" 2070 | }, 2071 | { 2072 | "type": "tidelift", 2073 | "url": "https://tidelift.com/funding/github/npm/postcss" 2074 | }, 2075 | { 2076 | "type": "github", 2077 | "url": "https://github.com/sponsors/ai" 2078 | } 2079 | ], 2080 | "license": "MIT", 2081 | "dependencies": { 2082 | "nanoid": "^3.3.8", 2083 | "picocolors": "^1.1.1", 2084 | "source-map-js": "^1.2.1" 2085 | }, 2086 | "engines": { 2087 | "node": "^10 || ^12 || >=14" 2088 | } 2089 | }, 2090 | "node_modules/prettier": { 2091 | "version": "3.5.3", 2092 | "resolved": "https://registry.npmjs.org/prettier/-/prettier-3.5.3.tgz", 2093 | "integrity": "sha512-QQtaxnoDJeAkDvDKWCLiwIXkTgRhwYDEQCghU9Z6q03iyek/rxRh/2lC3HB7P8sWT2xC/y5JDctPLBIGzHKbhw==", 2094 | "dev": true, 2095 | "license": "MIT", 2096 | "bin": { 2097 | "prettier": "bin/prettier.cjs" 2098 | }, 2099 | "engines": { 2100 | "node": ">=14" 2101 | }, 2102 | "funding": { 2103 | "url": "https://github.com/prettier/prettier?sponsor=1" 2104 | } 2105 | }, 2106 | "node_modules/queue-microtask": { 2107 | "version": "1.2.3", 2108 | "resolved": "https://registry.npmjs.org/queue-microtask/-/queue-microtask-1.2.3.tgz", 2109 | "integrity": "sha512-NuaNSa6flKT5JaSYQzJok04JzTL1CA6aGhv5rfLW3PgqA+M2ChpZQnAC8h8i4ZFkBS8X5RqkDBHA7r4hej3K9A==", 2110 | "dev": true, 2111 | "funding": [ 2112 | { 2113 | "type": "github", 2114 | "url": "https://github.com/sponsors/feross" 2115 | }, 2116 | { 2117 | "type": "patreon", 2118 | "url": "https://www.patreon.com/feross" 2119 | }, 2120 | { 2121 | "type": "consulting", 2122 | "url": "https://feross.org/support" 2123 | } 2124 | ], 2125 | "license": "MIT" 2126 | }, 2127 | "node_modules/readable-stream": { 2128 | "version": "3.6.2", 2129 | "resolved": "https://registry.npmjs.org/readable-stream/-/readable-stream-3.6.2.tgz", 2130 | "integrity": "sha512-9u/sniCrY3D5WdsERHzHE4G2YCXqoG5FTHUiCC4SIbr6XcLZBY05ya9EKjYek9O5xOAwjGq+1JdGBAS7Q9ScoA==", 2131 | "dev": true, 2132 | "license": "MIT", 2133 | "dependencies": { 2134 | "inherits": "^2.0.3", 2135 | "string_decoder": "^1.1.1", 2136 | "util-deprecate": "^1.0.1" 2137 | }, 2138 | "engines": { 2139 | "node": ">= 6" 2140 | } 2141 | }, 2142 | "node_modules/require-directory": { 2143 | "version": "2.1.1", 2144 | "resolved": "https://registry.npmjs.org/require-directory/-/require-directory-2.1.1.tgz", 2145 | "integrity": "sha512-fGxEI7+wsG9xrvdjsrlmL22OMTTiHRwAMroiEeMgq8gzoLC/PQr7RsRDSTLUg/bZAZtF+TVIkHc6/4RIKrui+Q==", 2146 | "dev": true, 2147 | "license": "MIT", 2148 | "engines": { 2149 | "node": ">=0.10.0" 2150 | } 2151 | }, 2152 | "node_modules/resolve": { 2153 | "version": "1.22.10", 2154 | "resolved": "https://registry.npmjs.org/resolve/-/resolve-1.22.10.tgz", 2155 | "integrity": "sha512-NPRy+/ncIMeDlTAsuqwKIiferiawhefFJtkNSW0qZJEqMEb+qBt/77B/jGeeek+F0uOeN05CDa6HXbbIgtVX4w==", 2156 | "dev": true, 2157 | "license": "MIT", 2158 | "dependencies": { 2159 | "is-core-module": "^2.16.0", 2160 | "path-parse": "^1.0.7", 2161 | "supports-preserve-symlinks-flag": "^1.0.0" 2162 | }, 2163 | "bin": { 2164 | "resolve": "bin/resolve" 2165 | }, 2166 | "engines": { 2167 | "node": ">= 0.4" 2168 | }, 2169 | "funding": { 2170 | "url": "https://github.com/sponsors/ljharb" 2171 | } 2172 | }, 2173 | "node_modules/resolve-pkg-maps": { 2174 | "version": "1.0.0", 2175 | "resolved": "https://registry.npmjs.org/resolve-pkg-maps/-/resolve-pkg-maps-1.0.0.tgz", 2176 | "integrity": "sha512-seS2Tj26TBVOC2NIc2rOe2y2ZO7efxITtLZcGSOnHHNOQ7CkiUBfw0Iw2ck6xkIhPwLhKNLS8BO+hEpngQlqzw==", 2177 | "dev": true, 2178 | "license": "MIT", 2179 | "funding": { 2180 | "url": "https://github.com/privatenumber/resolve-pkg-maps?sponsor=1" 2181 | } 2182 | }, 2183 | "node_modules/reusify": { 2184 | "version": "1.1.0", 2185 | "resolved": "https://registry.npmjs.org/reusify/-/reusify-1.1.0.tgz", 2186 | "integrity": "sha512-g6QUff04oZpHs0eG5p83rFLhHeV00ug/Yf9nZM6fLeUrPguBTkTQOdpAWWspMh55TZfVQDPaN3NQJfbVRAxdIw==", 2187 | "dev": true, 2188 | "license": "MIT", 2189 | "engines": { 2190 | "iojs": ">=1.0.0", 2191 | "node": ">=0.10.0" 2192 | } 2193 | }, 2194 | "node_modules/rollup": { 2195 | "version": "4.40.0", 2196 | "resolved": "https://registry.npmjs.org/rollup/-/rollup-4.40.0.tgz", 2197 | "integrity": "sha512-Noe455xmA96nnqH5piFtLobsGbCij7Tu+tb3c1vYjNbTkfzGqXqQXG3wJaYXkRZuQ0vEYN4bhwg7QnIrqB5B+w==", 2198 | "dev": true, 2199 | "license": "MIT", 2200 | "dependencies": { 2201 | "@types/estree": "1.0.7" 2202 | }, 2203 | "bin": { 2204 | "rollup": "dist/bin/rollup" 2205 | }, 2206 | "engines": { 2207 | "node": ">=18.0.0", 2208 | "npm": ">=8.0.0" 2209 | }, 2210 | "optionalDependencies": { 2211 | "@rollup/rollup-android-arm-eabi": "4.40.0", 2212 | "@rollup/rollup-android-arm64": "4.40.0", 2213 | "@rollup/rollup-darwin-arm64": "4.40.0", 2214 | "@rollup/rollup-darwin-x64": "4.40.0", 2215 | "@rollup/rollup-freebsd-arm64": "4.40.0", 2216 | "@rollup/rollup-freebsd-x64": "4.40.0", 2217 | "@rollup/rollup-linux-arm-gnueabihf": "4.40.0", 2218 | "@rollup/rollup-linux-arm-musleabihf": "4.40.0", 2219 | "@rollup/rollup-linux-arm64-gnu": "4.40.0", 2220 | "@rollup/rollup-linux-arm64-musl": "4.40.0", 2221 | "@rollup/rollup-linux-loongarch64-gnu": "4.40.0", 2222 | "@rollup/rollup-linux-powerpc64le-gnu": "4.40.0", 2223 | "@rollup/rollup-linux-riscv64-gnu": "4.40.0", 2224 | "@rollup/rollup-linux-riscv64-musl": "4.40.0", 2225 | "@rollup/rollup-linux-s390x-gnu": "4.40.0", 2226 | "@rollup/rollup-linux-x64-gnu": "4.40.0", 2227 | "@rollup/rollup-linux-x64-musl": "4.40.0", 2228 | "@rollup/rollup-win32-arm64-msvc": "4.40.0", 2229 | "@rollup/rollup-win32-ia32-msvc": "4.40.0", 2230 | "@rollup/rollup-win32-x64-msvc": "4.40.0", 2231 | "fsevents": "~2.3.2" 2232 | } 2233 | }, 2234 | "node_modules/rollup-pluginutils": { 2235 | "version": "2.8.2", 2236 | "resolved": "https://registry.npmjs.org/rollup-pluginutils/-/rollup-pluginutils-2.8.2.tgz", 2237 | "integrity": "sha512-EEp9NhnUkwY8aif6bxgovPHMoMoNr2FulJziTndpt5H9RdwC47GSGuII9XxpSdzVGM0GWrNPHV6ie1LTNJPaLQ==", 2238 | "dev": true, 2239 | "license": "MIT", 2240 | "dependencies": { 2241 | "estree-walker": "^0.6.1" 2242 | } 2243 | }, 2244 | "node_modules/rollup-pluginutils/node_modules/estree-walker": { 2245 | "version": "0.6.1", 2246 | "resolved": "https://registry.npmjs.org/estree-walker/-/estree-walker-0.6.1.tgz", 2247 | "integrity": "sha512-SqmZANLWS0mnatqbSfRP5g8OXZC12Fgg1IwNtLsyHDzJizORW4khDfjPqJZsemPWBB2uqykUah5YpQ6epsqC/w==", 2248 | "dev": true, 2249 | "license": "MIT" 2250 | }, 2251 | "node_modules/run-parallel": { 2252 | "version": "1.2.0", 2253 | "resolved": "https://registry.npmjs.org/run-parallel/-/run-parallel-1.2.0.tgz", 2254 | "integrity": "sha512-5l4VyZR86LZ/lDxZTR6jqL8AFE2S0IFLMP26AbjsLVADxHdhB/c0GUsH+y39UfCi3dzz8OlQuPmnaJOMoDHQBA==", 2255 | "dev": true, 2256 | "funding": [ 2257 | { 2258 | "type": "github", 2259 | "url": "https://github.com/sponsors/feross" 2260 | }, 2261 | { 2262 | "type": "patreon", 2263 | "url": "https://www.patreon.com/feross" 2264 | }, 2265 | { 2266 | "type": "consulting", 2267 | "url": "https://feross.org/support" 2268 | } 2269 | ], 2270 | "license": "MIT", 2271 | "dependencies": { 2272 | "queue-microtask": "^1.2.2" 2273 | } 2274 | }, 2275 | "node_modules/safe-buffer": { 2276 | "version": "5.2.1", 2277 | "resolved": "https://registry.npmjs.org/safe-buffer/-/safe-buffer-5.2.1.tgz", 2278 | "integrity": "sha512-rp3So07KcdmmKbGvgaNxQSJr7bGVSVk5S9Eq1F+ppbRo70+YeaDxkw5Dd8NPN+GD6bjnYm2VuPuCXmpuYvmCXQ==", 2279 | "dev": true, 2280 | "funding": [ 2281 | { 2282 | "type": "github", 2283 | "url": "https://github.com/sponsors/feross" 2284 | }, 2285 | { 2286 | "type": "patreon", 2287 | "url": "https://www.patreon.com/feross" 2288 | }, 2289 | { 2290 | "type": "consulting", 2291 | "url": "https://feross.org/support" 2292 | } 2293 | ], 2294 | "license": "MIT" 2295 | }, 2296 | "node_modules/siginfo": { 2297 | "version": "2.0.0", 2298 | "resolved": "https://registry.npmjs.org/siginfo/-/siginfo-2.0.0.tgz", 2299 | "integrity": "sha512-ybx0WO1/8bSBLEWXZvEd7gMW3Sn3JFlW3TvX1nREbDLRNQNaeNN8WK0meBwPdAaOI7TtRRRJn/Es1zhrrCHu7g==", 2300 | "dev": true, 2301 | "license": "ISC" 2302 | }, 2303 | "node_modules/source-map-js": { 2304 | "version": "1.2.1", 2305 | "resolved": "https://registry.npmjs.org/source-map-js/-/source-map-js-1.2.1.tgz", 2306 | "integrity": "sha512-UXWMKhLOwVKb728IUtQPXxfYU+usdybtUrK/8uGE8CQMvrhOpwvzDBwj0QhSL7MQc7vIsISBG8VQ8+IDQxpfQA==", 2307 | "dev": true, 2308 | "license": "BSD-3-Clause", 2309 | "engines": { 2310 | "node": ">=0.10.0" 2311 | } 2312 | }, 2313 | "node_modules/split2": { 2314 | "version": "3.2.2", 2315 | "resolved": "https://registry.npmjs.org/split2/-/split2-3.2.2.tgz", 2316 | "integrity": "sha512-9NThjpgZnifTkJpzTZ7Eue85S49QwpNhZTq6GRJwObb6jnLFNGB7Qm73V5HewTROPyxD0C29xqmaI68bQtV+hg==", 2317 | "dev": true, 2318 | "license": "ISC", 2319 | "dependencies": { 2320 | "readable-stream": "^3.0.0" 2321 | } 2322 | }, 2323 | "node_modules/stackback": { 2324 | "version": "0.0.2", 2325 | "resolved": "https://registry.npmjs.org/stackback/-/stackback-0.0.2.tgz", 2326 | "integrity": "sha512-1XMJE5fQo1jGH6Y/7ebnwPOBEkIEnT4QF32d5R1+VXdXveM0IBMJt8zfaxX1P3QhVwrYe+576+jkANtSS2mBbw==", 2327 | "dev": true, 2328 | "license": "MIT" 2329 | }, 2330 | "node_modules/std-env": { 2331 | "version": "3.9.0", 2332 | "resolved": "https://registry.npmjs.org/std-env/-/std-env-3.9.0.tgz", 2333 | "integrity": "sha512-UGvjygr6F6tpH7o2qyqR6QYpwraIjKSdtzyBdyytFOHmPZY917kwdwLG0RbOjWOnKmnm3PeHjaoLLMie7kPLQw==", 2334 | "dev": true, 2335 | "license": "MIT" 2336 | }, 2337 | "node_modules/string_decoder": { 2338 | "version": "1.3.0", 2339 | "resolved": "https://registry.npmjs.org/string_decoder/-/string_decoder-1.3.0.tgz", 2340 | "integrity": "sha512-hkRX8U1WjJFd8LsDJ2yQ/wWWxaopEsABU1XfkM8A+j0+85JAGppt16cr1Whg6KIbb4okU6Mql6BOj+uup/wKeA==", 2341 | "dev": true, 2342 | "license": "MIT", 2343 | "dependencies": { 2344 | "safe-buffer": "~5.2.0" 2345 | } 2346 | }, 2347 | "node_modules/string-width": { 2348 | "version": "4.2.3", 2349 | "resolved": "https://registry.npmjs.org/string-width/-/string-width-4.2.3.tgz", 2350 | "integrity": "sha512-wKyQRQpjJ0sIp62ErSZdGsjMJWsap5oRNihHhu6G7JVO/9jIB6UyevL+tXuOqrng8j/cxKTWyWUwvSTriiZz/g==", 2351 | "dev": true, 2352 | "license": "MIT", 2353 | "dependencies": { 2354 | "emoji-regex": "^8.0.0", 2355 | "is-fullwidth-code-point": "^3.0.0", 2356 | "strip-ansi": "^6.0.1" 2357 | }, 2358 | "engines": { 2359 | "node": ">=8" 2360 | } 2361 | }, 2362 | "node_modules/strip-ansi": { 2363 | "version": "6.0.1", 2364 | "resolved": "https://registry.npmjs.org/strip-ansi/-/strip-ansi-6.0.1.tgz", 2365 | "integrity": "sha512-Y38VPSHcqkFrCpFnQ9vuSXmquuv5oXOKpGeT6aGrr3o3Gc9AlVa6JBfUSOCnbxGGZF+/0ooI7KrPuUSztUdU5A==", 2366 | "dev": true, 2367 | "license": "MIT", 2368 | "dependencies": { 2369 | "ansi-regex": "^5.0.1" 2370 | }, 2371 | "engines": { 2372 | "node": ">=8" 2373 | } 2374 | }, 2375 | "node_modules/supports-color": { 2376 | "version": "7.2.0", 2377 | "resolved": "https://registry.npmjs.org/supports-color/-/supports-color-7.2.0.tgz", 2378 | "integrity": "sha512-qpCAvRl9stuOHveKsn7HncJRvv501qIacKzQlO/+Lwxc9+0q2wLyv4Dfvt80/DPn2pqOBsJdDiogXGR9+OvwRw==", 2379 | "dev": true, 2380 | "license": "MIT", 2381 | "dependencies": { 2382 | "has-flag": "^4.0.0" 2383 | }, 2384 | "engines": { 2385 | "node": ">=8" 2386 | } 2387 | }, 2388 | "node_modules/supports-preserve-symlinks-flag": { 2389 | "version": "1.0.0", 2390 | "resolved": "https://registry.npmjs.org/supports-preserve-symlinks-flag/-/supports-preserve-symlinks-flag-1.0.0.tgz", 2391 | "integrity": "sha512-ot0WnXS9fgdkgIcePe6RHNk1WA8+muPa6cSjeR3V8K27q9BB1rTE3R1p7Hv0z1ZyAc8s6Vvv8DIyWf681MAt0w==", 2392 | "dev": true, 2393 | "license": "MIT", 2394 | "engines": { 2395 | "node": ">= 0.4" 2396 | }, 2397 | "funding": { 2398 | "url": "https://github.com/sponsors/ljharb" 2399 | } 2400 | }, 2401 | "node_modules/through2": { 2402 | "version": "4.0.2", 2403 | "resolved": "https://registry.npmjs.org/through2/-/through2-4.0.2.tgz", 2404 | "integrity": "sha512-iOqSav00cVxEEICeD7TjLB1sueEL+81Wpzp2bY17uZjZN0pWZPuo4suZ/61VujxmqSGFfgOcNuTZ85QJwNZQpw==", 2405 | "dev": true, 2406 | "license": "MIT", 2407 | "dependencies": { 2408 | "readable-stream": "3" 2409 | } 2410 | }, 2411 | "node_modules/tinybench": { 2412 | "version": "2.9.0", 2413 | "resolved": "https://registry.npmjs.org/tinybench/-/tinybench-2.9.0.tgz", 2414 | "integrity": "sha512-0+DUvqWMValLmha6lr4kD8iAMK1HzV0/aKnCtWb9v9641TnP/MFb7Pc2bxoxQjTXAErryXVgUOfv2YqNllqGeg==", 2415 | "dev": true, 2416 | "license": "MIT" 2417 | }, 2418 | "node_modules/tinyexec": { 2419 | "version": "0.3.2", 2420 | "resolved": "https://registry.npmjs.org/tinyexec/-/tinyexec-0.3.2.tgz", 2421 | "integrity": "sha512-KQQR9yN7R5+OSwaK0XQoj22pwHoTlgYqmUscPYoknOoWCWfj/5/ABTMRi69FrKU5ffPVh5QcFikpWJI/P1ocHA==", 2422 | "dev": true, 2423 | "license": "MIT" 2424 | }, 2425 | "node_modules/tinyglobby": { 2426 | "version": "0.2.13", 2427 | "resolved": "https://registry.npmjs.org/tinyglobby/-/tinyglobby-0.2.13.tgz", 2428 | "integrity": "sha512-mEwzpUgrLySlveBwEVDMKk5B57bhLPYovRfPAXD5gA/98Opn0rCDj3GtLwFvCvH5RK9uPCExUROW5NjDwvqkxw==", 2429 | "dev": true, 2430 | "license": "MIT", 2431 | "dependencies": { 2432 | "fdir": "^6.4.4", 2433 | "picomatch": "^4.0.2" 2434 | }, 2435 | "engines": { 2436 | "node": ">=12.0.0" 2437 | }, 2438 | "funding": { 2439 | "url": "https://github.com/sponsors/SuperchupuDev" 2440 | } 2441 | }, 2442 | "node_modules/tinypool": { 2443 | "version": "1.0.2", 2444 | "resolved": "https://registry.npmjs.org/tinypool/-/tinypool-1.0.2.tgz", 2445 | "integrity": "sha512-al6n+QEANGFOMf/dmUMsuS5/r9B06uwlyNjZZql/zv8J7ybHCgoihBNORZCY2mzUuAnomQa2JdhyHKzZxPCrFA==", 2446 | "dev": true, 2447 | "license": "MIT", 2448 | "engines": { 2449 | "node": "^18.0.0 || >=20.0.0" 2450 | } 2451 | }, 2452 | "node_modules/tinyrainbow": { 2453 | "version": "2.0.0", 2454 | "resolved": "https://registry.npmjs.org/tinyrainbow/-/tinyrainbow-2.0.0.tgz", 2455 | "integrity": "sha512-op4nsTR47R6p0vMUUoYl/a+ljLFVtlfaXkLQmqfLR1qHma1h/ysYk4hEXZ880bf2CYgTskvTa/e196Vd5dDQXw==", 2456 | "dev": true, 2457 | "license": "MIT", 2458 | "engines": { 2459 | "node": ">=14.0.0" 2460 | } 2461 | }, 2462 | "node_modules/tinyspy": { 2463 | "version": "3.0.2", 2464 | "resolved": "https://registry.npmjs.org/tinyspy/-/tinyspy-3.0.2.tgz", 2465 | "integrity": "sha512-n1cw8k1k0x4pgA2+9XrOkFydTerNcJ1zWCO5Nn9scWHTD+5tp8dghT2x1uduQePZTZgd3Tupf+x9BxJjeJi77Q==", 2466 | "dev": true, 2467 | "license": "MIT", 2468 | "engines": { 2469 | "node": ">=14.0.0" 2470 | } 2471 | }, 2472 | "node_modules/to-regex-range": { 2473 | "version": "5.0.1", 2474 | "resolved": "https://registry.npmjs.org/to-regex-range/-/to-regex-range-5.0.1.tgz", 2475 | "integrity": "sha512-65P7iz6X5yEr1cwcgvQxbbIw7Uk3gOy5dIdtZ4rDveLqhrdJP+Li/Hx6tyK0NEb+2GCyneCMJiGqrADCSNk8sQ==", 2476 | "dev": true, 2477 | "license": "MIT", 2478 | "dependencies": { 2479 | "is-number": "^7.0.0" 2480 | }, 2481 | "engines": { 2482 | "node": ">=8.0" 2483 | } 2484 | }, 2485 | "node_modules/treeify": { 2486 | "version": "1.1.0", 2487 | "resolved": "https://registry.npmjs.org/treeify/-/treeify-1.1.0.tgz", 2488 | "integrity": "sha512-1m4RA7xVAJrSGrrXGs0L3YTwyvBs2S8PbRHaLZAkFw7JR8oIFwYtysxlBZhYIa7xSyiYJKZ3iGrrk55cGA3i9A==", 2489 | "dev": true, 2490 | "license": "MIT", 2491 | "engines": { 2492 | "node": ">=0.6" 2493 | } 2494 | }, 2495 | "node_modules/tsx": { 2496 | "version": "4.19.3", 2497 | "resolved": "https://registry.npmjs.org/tsx/-/tsx-4.19.3.tgz", 2498 | "integrity": "sha512-4H8vUNGNjQ4V2EOoGw005+c+dGuPSnhpPBPHBtsZdGZBk/iJb4kguGlPWaZTZ3q5nMtFOEsY0nRDlh9PJyd6SQ==", 2499 | "dev": true, 2500 | "license": "MIT", 2501 | "dependencies": { 2502 | "esbuild": "~0.25.0", 2503 | "get-tsconfig": "^4.7.5" 2504 | }, 2505 | "bin": { 2506 | "tsx": "dist/cli.mjs" 2507 | }, 2508 | "engines": { 2509 | "node": ">=18.0.0" 2510 | }, 2511 | "optionalDependencies": { 2512 | "fsevents": "~2.3.3" 2513 | } 2514 | }, 2515 | "node_modules/typescript": { 2516 | "version": "5.8.3", 2517 | "resolved": "https://registry.npmjs.org/typescript/-/typescript-5.8.3.tgz", 2518 | "integrity": "sha512-p1diW6TqL9L07nNxvRMM7hMMw4c5XOo/1ibL4aAIGmSAt9slTE1Xgw5KWuof2uTOvCg9BY7ZRi+GaF+7sfgPeQ==", 2519 | "dev": true, 2520 | "license": "Apache-2.0", 2521 | "bin": { 2522 | "tsc": "bin/tsc", 2523 | "tsserver": "bin/tsserver" 2524 | }, 2525 | "engines": { 2526 | "node": ">=14.17" 2527 | } 2528 | }, 2529 | "node_modules/util-deprecate": { 2530 | "version": "1.0.2", 2531 | "resolved": "https://registry.npmjs.org/util-deprecate/-/util-deprecate-1.0.2.tgz", 2532 | "integrity": "sha512-EPD5q1uXyFxJpCrLnCc1nHnq3gOa6DZBocAIiI2TaSCA7VCJ1UJDMagCzIkXNsUYfD1daK//LTEQ8xiIbrHtcw==", 2533 | "dev": true, 2534 | "license": "MIT" 2535 | }, 2536 | "node_modules/vite": { 2537 | "version": "6.3.2", 2538 | "resolved": "https://registry.npmjs.org/vite/-/vite-6.3.2.tgz", 2539 | "integrity": "sha512-ZSvGOXKGceizRQIZSz7TGJ0pS3QLlVY/9hwxVh17W3re67je1RKYzFHivZ/t0tubU78Vkyb9WnHPENSBCzbckg==", 2540 | "dev": true, 2541 | "license": "MIT", 2542 | "dependencies": { 2543 | "esbuild": "^0.25.0", 2544 | "fdir": "^6.4.3", 2545 | "picomatch": "^4.0.2", 2546 | "postcss": "^8.5.3", 2547 | "rollup": "^4.34.9", 2548 | "tinyglobby": "^0.2.12" 2549 | }, 2550 | "bin": { 2551 | "vite": "bin/vite.js" 2552 | }, 2553 | "engines": { 2554 | "node": "^18.0.0 || ^20.0.0 || >=22.0.0" 2555 | }, 2556 | "funding": { 2557 | "url": "https://github.com/vitejs/vite?sponsor=1" 2558 | }, 2559 | "optionalDependencies": { 2560 | "fsevents": "~2.3.3" 2561 | }, 2562 | "peerDependencies": { 2563 | "@types/node": "^18.0.0 || ^20.0.0 || >=22.0.0", 2564 | "jiti": ">=1.21.0", 2565 | "less": "*", 2566 | "lightningcss": "^1.21.0", 2567 | "sass": "*", 2568 | "sass-embedded": "*", 2569 | "stylus": "*", 2570 | "sugarss": "*", 2571 | "terser": "^5.16.0", 2572 | "tsx": "^4.8.1", 2573 | "yaml": "^2.4.2" 2574 | }, 2575 | "peerDependenciesMeta": { 2576 | "@types/node": { 2577 | "optional": true 2578 | }, 2579 | "jiti": { 2580 | "optional": true 2581 | }, 2582 | "less": { 2583 | "optional": true 2584 | }, 2585 | "lightningcss": { 2586 | "optional": true 2587 | }, 2588 | "sass": { 2589 | "optional": true 2590 | }, 2591 | "sass-embedded": { 2592 | "optional": true 2593 | }, 2594 | "stylus": { 2595 | "optional": true 2596 | }, 2597 | "sugarss": { 2598 | "optional": true 2599 | }, 2600 | "terser": { 2601 | "optional": true 2602 | }, 2603 | "tsx": { 2604 | "optional": true 2605 | }, 2606 | "yaml": { 2607 | "optional": true 2608 | } 2609 | } 2610 | }, 2611 | "node_modules/vite-node": { 2612 | "version": "3.1.2", 2613 | "resolved": "https://registry.npmjs.org/vite-node/-/vite-node-3.1.2.tgz", 2614 | "integrity": "sha512-/8iMryv46J3aK13iUXsei5G/A3CUlW4665THCPS+K8xAaqrVWiGB4RfXMQXCLjpK9P2eK//BczrVkn5JLAk6DA==", 2615 | "dev": true, 2616 | "license": "MIT", 2617 | "dependencies": { 2618 | "cac": "^6.7.14", 2619 | "debug": "^4.4.0", 2620 | "es-module-lexer": "^1.6.0", 2621 | "pathe": "^2.0.3", 2622 | "vite": "^5.0.0 || ^6.0.0" 2623 | }, 2624 | "bin": { 2625 | "vite-node": "vite-node.mjs" 2626 | }, 2627 | "engines": { 2628 | "node": "^18.0.0 || ^20.0.0 || >=22.0.0" 2629 | }, 2630 | "funding": { 2631 | "url": "https://opencollective.com/vitest" 2632 | } 2633 | }, 2634 | "node_modules/vitest": { 2635 | "version": "3.1.2", 2636 | "resolved": "https://registry.npmjs.org/vitest/-/vitest-3.1.2.tgz", 2637 | "integrity": "sha512-WaxpJe092ID1C0mr+LH9MmNrhfzi8I65EX/NRU/Ld016KqQNRgxSOlGNP1hHN+a/F8L15Mh8klwaF77zR3GeDQ==", 2638 | "dev": true, 2639 | "license": "MIT", 2640 | "dependencies": { 2641 | "@vitest/expect": "3.1.2", 2642 | "@vitest/mocker": "3.1.2", 2643 | "@vitest/pretty-format": "^3.1.2", 2644 | "@vitest/runner": "3.1.2", 2645 | "@vitest/snapshot": "3.1.2", 2646 | "@vitest/spy": "3.1.2", 2647 | "@vitest/utils": "3.1.2", 2648 | "chai": "^5.2.0", 2649 | "debug": "^4.4.0", 2650 | "expect-type": "^1.2.1", 2651 | "magic-string": "^0.30.17", 2652 | "pathe": "^2.0.3", 2653 | "std-env": "^3.9.0", 2654 | "tinybench": "^2.9.0", 2655 | "tinyexec": "^0.3.2", 2656 | "tinyglobby": "^0.2.13", 2657 | "tinypool": "^1.0.2", 2658 | "tinyrainbow": "^2.0.0", 2659 | "vite": "^5.0.0 || ^6.0.0", 2660 | "vite-node": "3.1.2", 2661 | "why-is-node-running": "^2.3.0" 2662 | }, 2663 | "bin": { 2664 | "vitest": "vitest.mjs" 2665 | }, 2666 | "engines": { 2667 | "node": "^18.0.0 || ^20.0.0 || >=22.0.0" 2668 | }, 2669 | "funding": { 2670 | "url": "https://opencollective.com/vitest" 2671 | }, 2672 | "peerDependencies": { 2673 | "@edge-runtime/vm": "*", 2674 | "@types/debug": "^4.1.12", 2675 | "@types/node": "^18.0.0 || ^20.0.0 || >=22.0.0", 2676 | "@vitest/browser": "3.1.2", 2677 | "@vitest/ui": "3.1.2", 2678 | "happy-dom": "*", 2679 | "jsdom": "*" 2680 | }, 2681 | "peerDependenciesMeta": { 2682 | "@edge-runtime/vm": { 2683 | "optional": true 2684 | }, 2685 | "@types/debug": { 2686 | "optional": true 2687 | }, 2688 | "@types/node": { 2689 | "optional": true 2690 | }, 2691 | "@vitest/browser": { 2692 | "optional": true 2693 | }, 2694 | "@vitest/ui": { 2695 | "optional": true 2696 | }, 2697 | "happy-dom": { 2698 | "optional": true 2699 | }, 2700 | "jsdom": { 2701 | "optional": true 2702 | } 2703 | } 2704 | }, 2705 | "node_modules/why-is-node-running": { 2706 | "version": "2.3.0", 2707 | "resolved": "https://registry.npmjs.org/why-is-node-running/-/why-is-node-running-2.3.0.tgz", 2708 | "integrity": "sha512-hUrmaWBdVDcxvYqnyh09zunKzROWjbZTiNy8dBEjkS7ehEDQibXJ7XvlmtbwuTclUiIyN+CyXQD4Vmko8fNm8w==", 2709 | "dev": true, 2710 | "license": "MIT", 2711 | "dependencies": { 2712 | "siginfo": "^2.0.0", 2713 | "stackback": "0.0.2" 2714 | }, 2715 | "bin": { 2716 | "why-is-node-running": "cli.js" 2717 | }, 2718 | "engines": { 2719 | "node": ">=8" 2720 | } 2721 | }, 2722 | "node_modules/wrap-ansi": { 2723 | "version": "7.0.0", 2724 | "resolved": "https://registry.npmjs.org/wrap-ansi/-/wrap-ansi-7.0.0.tgz", 2725 | "integrity": "sha512-YVGIj2kamLSTxw6NsZjoBxfSwsn0ycdesmc4p+Q21c5zPuZ1pl+NfxVdxPtdHvmNVOQ6XSYG4AUtyt/Fi7D16Q==", 2726 | "dev": true, 2727 | "license": "MIT", 2728 | "dependencies": { 2729 | "ansi-styles": "^4.0.0", 2730 | "string-width": "^4.1.0", 2731 | "strip-ansi": "^6.0.0" 2732 | }, 2733 | "engines": { 2734 | "node": ">=10" 2735 | }, 2736 | "funding": { 2737 | "url": "https://github.com/chalk/wrap-ansi?sponsor=1" 2738 | } 2739 | }, 2740 | "node_modules/y18n": { 2741 | "version": "5.0.8", 2742 | "resolved": "https://registry.npmjs.org/y18n/-/y18n-5.0.8.tgz", 2743 | "integrity": "sha512-0pfFzegeDWJHJIAmTLRP2DwHjdF5s7jo9tuztdQxAhINCdvS+3nGINqPd00AphqJR/0LhANUS6/+7SCb98YOfA==", 2744 | "dev": true, 2745 | "license": "ISC", 2746 | "engines": { 2747 | "node": ">=10" 2748 | } 2749 | }, 2750 | "node_modules/yargs": { 2751 | "version": "16.2.0", 2752 | "resolved": "https://registry.npmjs.org/yargs/-/yargs-16.2.0.tgz", 2753 | "integrity": "sha512-D1mvvtDG0L5ft/jGWkLpG1+m0eQxOfaBvTNELraWj22wSVUMWxZUvYgJYcKh6jGGIkJFhH4IZPQhR4TKpc8mBw==", 2754 | "dev": true, 2755 | "license": "MIT", 2756 | "dependencies": { 2757 | "cliui": "^7.0.2", 2758 | "escalade": "^3.1.1", 2759 | "get-caller-file": "^2.0.5", 2760 | "require-directory": "^2.1.1", 2761 | "string-width": "^4.2.0", 2762 | "y18n": "^5.0.5", 2763 | "yargs-parser": "^20.2.2" 2764 | }, 2765 | "engines": { 2766 | "node": ">=10" 2767 | } 2768 | }, 2769 | "node_modules/yargs-parser": { 2770 | "version": "20.2.9", 2771 | "resolved": "https://registry.npmjs.org/yargs-parser/-/yargs-parser-20.2.9.tgz", 2772 | "integrity": "sha512-y11nGElTIV+CT3Zv9t7VKl+Q3hTQoT9a1Qzezhhl6Rp21gJ/IVTW7Z3y9EWXhuUBC2Shnf+DX0antecpAwSP8w==", 2773 | "dev": true, 2774 | "license": "ISC", 2775 | "engines": { 2776 | "node": ">=10" 2777 | } 2778 | }, 2779 | "node_modules/yocto-queue": { 2780 | "version": "0.1.0", 2781 | "resolved": "https://registry.npmjs.org/yocto-queue/-/yocto-queue-0.1.0.tgz", 2782 | "integrity": "sha512-rVksvsnNCdJ/ohGc6xgPwyN8eheCxsiLM8mxuE/t/mOVqJewPuO1miLpTHQiRgTKCLexL4MeAFVagts7HmNZ2Q==", 2783 | "dev": true, 2784 | "license": "MIT", 2785 | "engines": { 2786 | "node": ">=10" 2787 | }, 2788 | "funding": { 2789 | "url": "https://github.com/sponsors/sindresorhus" 2790 | } 2791 | } 2792 | } 2793 | } 2794 | -------------------------------------------------------------------------------- /package.json: -------------------------------------------------------------------------------- 1 | { 2 | "name": "go-go-try", 3 | "version": "6.2.0", 4 | "description": "Tries to execute a sync/async function, returns a result tuple", 5 | "license": "MIT", 6 | "repository": "thelinuxlich/go-go-try", 7 | "author": { 8 | "name": "Alisson Cavalcante Agiani", 9 | "email": "thelinuxlich@gmail.com" 10 | }, 11 | "type": "module", 12 | "main": "./dist/index.cjs", 13 | "module": "./dist/index.mjs", 14 | "types": "./dist/index.d.mts", 15 | "exports": { 16 | "require": { 17 | "types": "./dist/index.d.cts", 18 | "default": "./dist/index.cjs" 19 | }, 20 | "import": { 21 | "types": "./dist/index.d.mts", 22 | "default": "./dist/index.mjs" 23 | } 24 | }, 25 | "engines": { 26 | "node": ">=16" 27 | }, 28 | "scripts": { 29 | "build": "pkgroll", 30 | "lint": "biome lint --write src/*.ts", 31 | "test": "npm run build && npm run lint && vitest run" 32 | }, 33 | "keywords": [ 34 | "errors", 35 | "try", 36 | "catch", 37 | "error handling", 38 | "nice-try", 39 | "good-try", 40 | "neverthrow", 41 | "ts-result", 42 | "effect", 43 | "go-go-try", 44 | "gotry", 45 | "go-try" 46 | ], 47 | "devDependencies": { 48 | "@ark/attest": "^0.46.0", 49 | "@biomejs/biome": "^1.9.4", 50 | "pkgroll": "^2.12.1", 51 | "tsx": "^4.19.3", 52 | "typescript": "^5.8.3", 53 | "vitest": "^3.1.2" 54 | } 55 | } 56 | -------------------------------------------------------------------------------- /setupVitest.ts: -------------------------------------------------------------------------------- 1 | import { setup } from "@ark/attest"; 2 | export default () => setup({}); 3 | -------------------------------------------------------------------------------- /src/index.test.ts: -------------------------------------------------------------------------------- 1 | import { attest } from '@ark/attest' 2 | import { assert, describe, test } from 'vitest' 3 | import { type Result, goTry, goTryRaw, isFailure, isSuccess } from './index.js' 4 | 5 | test(`value returned by callback is used when callback doesn't throw`, async () => { 6 | const fn = () => 'value' 7 | 8 | // Test with function 9 | const result1 = goTry(fn) 10 | const result2 = goTryRaw(fn) 11 | 12 | // Test destructuring 13 | const [err1, value] = result1 14 | const [err2, value2] = result2 15 | 16 | // Test type guards 17 | assert.equal(isSuccess(result1), true) 18 | assert.equal(isSuccess(result2), true) 19 | assert.equal(isFailure(result1), false) 20 | assert.equal(isFailure(result2), false) 21 | 22 | // Test values 23 | assert.equal(value, 'value') 24 | assert.equal(value2, 'value') 25 | assert.equal(err1, undefined) 26 | assert.equal(err2, undefined) 27 | }) 28 | 29 | test('if function throws undefined, err should be "undefined"', async () => { 30 | const fn = () => { 31 | throw undefined 32 | } 33 | 34 | // Test with function that throws undefined 35 | const result1 = goTry(fn) 36 | const result2 = goTryRaw(fn) 37 | 38 | // Test destructuring 39 | const [err1, value] = result1 40 | const [err2, value2] = result2 41 | 42 | // Test type guards 43 | assert.equal(isSuccess(result1), false) 44 | assert.equal(isSuccess(result2), false) 45 | assert.equal(isFailure(result1), true) 46 | assert.equal(isFailure(result2), true) 47 | 48 | // Test values 49 | assert.equal(value, undefined) 50 | assert.equal(value2, undefined) 51 | assert.equal(err1, 'undefined') 52 | assert.equal(typeof err2, 'object') 53 | }) 54 | 55 | test('if callback throws, value should be undefined and err should contain the error message', async () => { 56 | const fn = () => { 57 | return JSON.parse('{/') as string 58 | } 59 | 60 | // Test with function that throws 61 | const result1 = goTry(fn) 62 | const result2 = goTryRaw(fn) 63 | 64 | // Test destructuring 65 | const [err1, value] = result1 66 | const [err2, value2] = result2 67 | 68 | // Test type guards 69 | assert.equal(isSuccess(result1), false) 70 | assert.equal(isSuccess(result2), false) 71 | assert.equal(isFailure(result1), true) 72 | assert.equal(isFailure(result2), true) 73 | 74 | // Test values 75 | assert.equal(value, undefined) 76 | assert.equal(value2, undefined) 77 | assert.equal(typeof err1, 'string') 78 | assert.equal(typeof err2, 'object') 79 | assert.equal(typeof err2?.message, 'string') 80 | }) 81 | 82 | test('first parameter accepts promises and makes the function async', async () => { 83 | const promise = Promise.resolve('value') 84 | 85 | // Test with promise 86 | const result1 = await goTry(promise) 87 | const result2 = await goTryRaw(promise) 88 | 89 | // Test destructuring 90 | const [err1, value] = result1 91 | const [err2, value2] = result2 92 | 93 | // Test type guards 94 | assert.equal(isSuccess(result1), true) 95 | assert.equal(isSuccess(result2), true) 96 | assert.equal(isFailure(result1), false) 97 | assert.equal(isFailure(result2), false) 98 | 99 | // Test values 100 | assert.equal(value, 'value') 101 | assert.equal(value2, 'value') 102 | assert.equal(err1, undefined) 103 | assert.equal(err2, undefined) 104 | }) 105 | 106 | test("if it's a function returning a Promise, should unwrap the value correctly to T", async () => { 107 | const fn = () => Promise.resolve('value') 108 | 109 | // Test with function that returns a promise 110 | const result1 = await goTry(fn) 111 | const result2 = await goTryRaw(fn) 112 | 113 | // Test destructuring 114 | const [err1, value] = result1 115 | const [err2, value2] = result2 116 | 117 | attest(err1) 118 | attest(value) 119 | 120 | attest(err2) 121 | attest(value2) 122 | 123 | // Test type guards 124 | assert.equal(isSuccess(result1), true) 125 | assert.equal(isSuccess(result2), true) 126 | assert.equal(isFailure(result1), false) 127 | assert.equal(isFailure(result2), false) 128 | 129 | // Test values 130 | assert.equal(value, 'value') 131 | assert.equal(value2, 'value') 132 | assert.equal(err1, undefined) 133 | assert.equal(err2, undefined) 134 | }) 135 | 136 | test('if async callback throws, value should be undefined and err should contain the error message', async () => { 137 | const promise = Promise.reject(new Error('error')) 138 | 139 | // Test with promise that rejects 140 | const result1 = await goTry(promise) 141 | const result2 = await goTryRaw(promise) 142 | 143 | // Test destructuring 144 | const [err, value] = result1 145 | const [err2, value2] = result2 146 | 147 | // Test type guards 148 | assert.equal(isSuccess(result1), false) 149 | assert.equal(isSuccess(result2), false) 150 | assert.equal(isFailure(result1), true) 151 | assert.equal(isFailure(result2), true) 152 | 153 | // Test values 154 | assert.equal(value, undefined) 155 | assert.equal(value2, undefined) 156 | assert.equal(err, 'error') 157 | assert.equal(typeof err2, 'object') 158 | assert.equal(err2?.message, 'error') 159 | }) 160 | 161 | test('direct values work too', () => { 162 | // Test with direct value 163 | const result1 = goTry('value') 164 | const result2 = goTryRaw('value') 165 | 166 | // Test destructuring 167 | const [err1, value] = result1 168 | const [err2, value2] = result2 169 | 170 | // Test values 171 | assert.equal(value, 'value') 172 | assert.equal(value2, 'value') 173 | assert.equal(err1, undefined) 174 | assert.equal(err2, undefined) 175 | }) 176 | 177 | test('async functions work correctly', async () => { 178 | // Define an async function 179 | function asyncFn() { 180 | return Promise.resolve(42) 181 | } 182 | 183 | // Test with async function 184 | const result1 = await goTry(asyncFn()) 185 | const result2 = await goTryRaw(asyncFn()) 186 | 187 | // Test destructuring 188 | const [err1, value] = result1 189 | const [err2, value2] = result2 190 | 191 | // Test values 192 | assert.equal(value, 42) 193 | assert.equal(value2, 42) 194 | assert.equal(err1, undefined) 195 | assert.equal(err2, undefined) 196 | }) 197 | 198 | test('async functions that throw work correctly', async () => { 199 | // Define an async function that throws 200 | async function asyncFnThatThrows() { 201 | await 1 202 | throw new Error('async error') 203 | } 204 | 205 | // Test with async function that throws 206 | const result1 = await goTry(asyncFnThatThrows()) 207 | const result2 = await goTryRaw(asyncFnThatThrows()) 208 | 209 | // Test destructuring 210 | const [err1, value] = result1 211 | const [err2, value2] = result2 212 | 213 | // Test values 214 | assert.equal(value, undefined) 215 | assert.equal(value2, undefined) 216 | assert.equal(err1, 'async error') 217 | assert.equal(typeof err2, 'object') 218 | assert.equal(err2?.message, 'async error') 219 | }) 220 | 221 | describe('goTry type tests', () => { 222 | test('synchronous function returns correct types', () => { 223 | const fn = () => 'value' 224 | const result = goTry(fn) 225 | 226 | // Check the result type 227 | attest>(result) 228 | 229 | // Check the destructured types 230 | const [err, value] = result 231 | attest(err) 232 | attest(value) 233 | 234 | // When destructured, the types should be narrowed correctly 235 | if (err === undefined) { 236 | attest(value) 237 | } else { 238 | attest(value) 239 | } 240 | }) 241 | 242 | test('direct value returns correct types', () => { 243 | const result = goTry('value') 244 | 245 | // Check the result type 246 | attest>(result) 247 | 248 | // Check the destructured types 249 | const [err, value] = result 250 | attest(err) 251 | attest(value) 252 | 253 | // When destructured, the types should be narrowed correctly 254 | if (err === undefined) { 255 | attest(value) 256 | } else { 257 | attest(value) 258 | } 259 | }) 260 | 261 | test('promise returns correct types', async () => { 262 | const promise = Promise.resolve('value') 263 | const result = await goTry(promise) 264 | 265 | // Check the result type 266 | attest>(result) 267 | 268 | // Check the destructured types 269 | const [err, value] = result 270 | attest(err) 271 | attest(value) 272 | 273 | // When destructured, the types should be narrowed correctly 274 | if (err === undefined) { 275 | attest(value) 276 | } else { 277 | attest(value) 278 | } 279 | }) 280 | 281 | test('async function returns correct types', async () => { 282 | const asyncFn = async () => 'value' 283 | const result = await goTry(asyncFn()) 284 | 285 | // Check the result type 286 | attest>(result) 287 | 288 | // Check the destructured types 289 | const [err, value] = result 290 | attest(err) 291 | attest(value) 292 | 293 | // When destructured, the types should be narrowed correctly 294 | if (err === undefined) { 295 | attest(value) 296 | } else { 297 | attest(value) 298 | } 299 | }) 300 | }) 301 | 302 | describe('goTryRaw type tests', () => { 303 | test('type inference works correctly', () => { 304 | const fn = () => 'value' 305 | const result = goTryRaw(fn) 306 | 307 | // Check the result type 308 | attest>(result) 309 | 310 | // Check the destructured types 311 | const [err, value] = result 312 | attest(err) 313 | attest(value) 314 | 315 | // When destructured, the types should be narrowed correctly 316 | if (err === undefined) { 317 | attest(value) 318 | } else { 319 | attest(value) 320 | } 321 | }) 322 | test('synchronous function returns correct types', () => { 323 | const fn = () => 'value' 324 | const result = goTryRaw(fn) 325 | 326 | // Check the result type 327 | attest>(result) 328 | 329 | // Check the destructured types 330 | const [err, value] = result 331 | attest(err) 332 | attest(value) 333 | 334 | // When destructured, the types should be narrowed correctly 335 | if (err === undefined) { 336 | attest(value) 337 | } else { 338 | attest(value) 339 | } 340 | }) 341 | 342 | test('direct value returns correct types', () => { 343 | const result = goTryRaw('value') 344 | 345 | // Check the result type 346 | attest>(result) 347 | 348 | // Check the destructured types 349 | const [err, value] = result 350 | attest(err) 351 | attest(value) 352 | 353 | // When destructured, the types should be narrowed correctly 354 | if (err === undefined) { 355 | attest(value) 356 | } else { 357 | attest(value) 358 | } 359 | }) 360 | 361 | test('promise returns correct types', async () => { 362 | const promise = Promise.resolve('value') 363 | const result = await goTryRaw(promise) 364 | 365 | // Check the result type 366 | attest>(result) 367 | 368 | // Check the destructured types 369 | const [err, value] = result 370 | attest(err) 371 | attest(value) 372 | 373 | // When destructured, the types should be narrowed correctly 374 | if (err === undefined) { 375 | attest(value) 376 | } else { 377 | attest(value) 378 | } 379 | }) 380 | 381 | test('async function returns correct types', async () => { 382 | const asyncFn = async () => 'value' 383 | const result = await goTryRaw(asyncFn()) 384 | 385 | // Check the result type 386 | attest>(result) 387 | 388 | // Check the destructured types 389 | const [err, value] = result 390 | attest(err) 391 | attest(value) 392 | 393 | // When destructured, the types should be narrowed correctly 394 | if (err === undefined) { 395 | attest(value) 396 | } else { 397 | attest(value) 398 | } 399 | }) 400 | }) 401 | -------------------------------------------------------------------------------- /src/index.ts: -------------------------------------------------------------------------------- 1 | export type Success = readonly [undefined, T] 2 | export type Failure = readonly [E, undefined] 3 | export type Result = Success | Failure 4 | 5 | export type MaybePromise = T | Promise 6 | 7 | export function isSuccess(result: Result): result is Success { 8 | return result[0] === undefined 9 | } 10 | export function isFailure(result: Result): result is Failure { 11 | return result[0] !== undefined 12 | } 13 | 14 | export function success(value: T): Success { 15 | return [undefined, value] as const 16 | } 17 | 18 | export function failure(error: E): Failure { 19 | return [error, undefined] as const 20 | } 21 | 22 | function getErrorMessage(error: unknown): string { 23 | if (error === undefined) return 'undefined' 24 | 25 | if (typeof error === 'string') return error 26 | 27 | if ( 28 | typeof error === 'object' && 29 | error !== null && 30 | 'message' in error && 31 | typeof (error as Record).message === 'string' 32 | ) { 33 | return (error as { message: string }).message 34 | } 35 | 36 | try { 37 | return JSON.stringify(error) 38 | } catch { 39 | // fallback in case there's an error stringifying the error 40 | // with circular references for example. 41 | return String(error) 42 | } 43 | } 44 | 45 | function isPromise(value: unknown): value is Promise { 46 | return ( 47 | typeof value === 'object' && 48 | value !== null && 49 | 'then' in value && 50 | typeof (value as { then: unknown }).then === 'function' 51 | ) 52 | } 53 | 54 | function isError(value: unknown): value is Error { 55 | return value instanceof Error 56 | } 57 | 58 | /** 59 | * Executes a function, promise, or value and returns a Result type. 60 | * If an error occurs, it returns a Failure with the error message as a string. 61 | * 62 | * @template T The type of the successful result 63 | * @param {T | Promise | (() => T | Promise)} value - The value, promise, or function to execute 64 | * @returns {Result | Promise>} A Result type or a Promise of a Result type 65 | * 66 | * @example 67 | * // With a value 68 | * const [err, result] = goTry(42); 69 | * 70 | * @example 71 | * // With a function 72 | * const [err, result] = goTry(() => JSON.parse('{"key": "value"}')); 73 | * 74 | * @example 75 | * // With a promise 76 | * const [err, result] = await goTry(fetch('https://api.example.com/data')); 77 | */ 78 | export function goTry(fn: () => never): Result 79 | export function goTry(fn: () => Promise): Promise> 80 | export function goTry(promise: Promise): Promise> 81 | export function goTry(fn: () => T): Result 82 | export function goTry(value: T): Result 83 | export function goTry( 84 | value: T | Promise | (() => T | Promise), 85 | ): Result | Promise> { 86 | try { 87 | const result = 88 | typeof value === 'function' ? (value as () => T | Promise)() : value 89 | if (isPromise(result)) { 90 | return result 91 | .then((resolvedValue) => success(resolvedValue)) 92 | .catch((err) => failure(getErrorMessage(err))) 93 | } 94 | return success(result) 95 | } catch (err) { 96 | return failure(getErrorMessage(err)) 97 | } 98 | } 99 | 100 | /** 101 | * Executes a function, promise, or value and returns a Result type. 102 | * If an error occurs, it returns a Failure with the raw error object. 103 | * 104 | * @template T The type of the successful result 105 | * @template E The type of the error, defaults to Error 106 | * @param {T | Promise | (() => T | Promise)} value - The value, promise, or function to execute 107 | * @returns {Result | Promise>} A Result type or a Promise of a Result type 108 | * 109 | * @example 110 | * // With a value 111 | * const [err, result] = goTryRaw(42); 112 | * 113 | * @example 114 | * // With a function 115 | * const [err, result] = goTryRaw(() => JSON.parse('{"key": "value"}')); 116 | * 117 | * @example 118 | * // With a promise 119 | * const [err, result] = await goTryRaw(fetch('https://api.example.com/data')); 120 | */ 121 | export function goTryRaw(fn: () => never): Result 122 | export function goTryRaw( 123 | fn: () => Promise, 124 | ): Promise> 125 | export function goTryRaw( 126 | promise: Promise, 127 | ): Promise> 128 | export function goTryRaw(fn: () => T): Result 129 | export function goTryRaw(value: T): Result 130 | export function goTryRaw( 131 | value: T | Promise | (() => T | Promise), 132 | ): Result | Promise> { 133 | try { 134 | const result = 135 | typeof value === 'function' ? (value as () => T | Promise)() : value 136 | if (isPromise(result)) { 137 | return result 138 | .then((resolvedValue) => success(resolvedValue)) 139 | .catch((err) => { 140 | if (err === undefined) { 141 | return failure(new Error('undefined') as unknown as E) 142 | } 143 | return failure( 144 | isError(err) 145 | ? (err as unknown as E) 146 | : (new Error(String(err)) as unknown as E), 147 | ) 148 | }) 149 | } 150 | return success(result) 151 | } catch (err) { 152 | return failure( 153 | isError(err) 154 | ? (err as unknown as E) 155 | : (new Error(String(err)) as unknown as E), 156 | ) 157 | } 158 | } 159 | -------------------------------------------------------------------------------- /tsconfig.json: -------------------------------------------------------------------------------- 1 | { 2 | "compilerOptions": { 3 | "target": "ES2020", 4 | "module": "ES2015", 5 | "esModuleInterop": true, 6 | "moduleResolution": "node", 7 | "declaration": true, 8 | "declarationMap": true, 9 | "inlineSourceMap": true, 10 | "isolatedModules": true, 11 | "strict": true, 12 | "noUnusedLocals": true, 13 | "noUnusedParameters": true, 14 | "allowUnreachableCode": false, 15 | "noUncheckedIndexedAccess": true, 16 | "noFallthroughCasesInSwitch": true, 17 | "forceConsistentCasingInFileNames": true 18 | }, 19 | "include": [ 20 | "src/**/*" 21 | ] 22 | } -------------------------------------------------------------------------------- /vitest.config.ts: -------------------------------------------------------------------------------- 1 | import { defineConfig } from "vitest/config"; 2 | 3 | export default defineConfig({ 4 | test: { 5 | globalSetup: ["setupVitest.ts"], 6 | typecheck: { 7 | enabled: true, 8 | }, 9 | }, 10 | }); 11 | --------------------------------------------------------------------------------