diff --git a/CHANGELOG.md b/CHANGELOG.md index e553b43..e35aa29 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -1,6 +1,31 @@ # Changelog +## v0.2.11 + +[compare changes](https://github.com/unjs/magicast/compare/v0.2.10...v0.2.11) + +### 🚀 Enhancements + +- **helpers:** Handle Vite config declarations with `satisfies` keyword ([#82](https://github.com/unjs/magicast/pull/82)) + +### 🏡 Chore + +- **release:** V0.2.10 ([4faf487](https://github.com/unjs/magicast/commit/4faf487)) +- Use v8 coverage ([c1277a7](https://github.com/unjs/magicast/commit/c1277a7)) +- Update deps, lint with new prettier ([30df539](https://github.com/unjs/magicast/commit/30df539)) +- Update tsconfig ([02743d3](https://github.com/unjs/magicast/commit/02743d3)) +- Lint ([4601589](https://github.com/unjs/magicast/commit/4601589)) + +### 🤖 CI + +- Update lint order ([5a5d49d](https://github.com/unjs/magicast/commit/5a5d49d)) + +### ❤️ Contributors + +- Lukas Stracke +- Anthony Fu + ## v0.2.10 [compare changes](https://github.com/unjs/magicast/compare/v0.2.9...v0.2.10) diff --git a/build.config.ts b/build.config.ts index e1bd1f1..6735827 100644 --- a/build.config.ts +++ b/build.config.ts @@ -15,8 +15,6 @@ export default defineBuildConfig({ alias: { 'source-map': 'source-map-js', // eslint-disable-next-line unicorn/prefer-module - assert: resolve(__dirname, 'stubs/assert/index.js'), - // eslint-disable-next-line unicorn/prefer-module recast: resolve(__dirname, 'vendor/recast/main.ts'), // eslint-disable-next-line unicorn/prefer-module 'ast-types': resolve(__dirname, 'vendor/ast-types/src/main.ts'), diff --git a/package.json b/package.json index 7addaa0..89716fd 100644 --- a/package.json +++ b/package.json @@ -1,6 +1,6 @@ { "name": "magicast", - "version": "0.2.10", + "version": "0.2.11", "description": "Modify a JS/TS file and write back magically just like JSON!", "repository": "unjs/magicast", "license": "MIT", @@ -40,17 +40,17 @@ "test:full": "pnpm run test && pnpm run build && pnpm run test:build" }, "dependencies": { - "@babel/parser": "^7.22.15", - "@babel/types": "^7.22.15", + "@babel/parser": "^7.22.16", + "@babel/types": "^7.22.19", "source-map-js": "^1.0.2" }, "devDependencies": { - "@types/node": "^20.5.9", - "@vitest/coverage-v8": "^0.34.3", - "@vitest/ui": "^0.34.3", + "@types/node": "^20.6.0", + "@vitest/coverage-v8": "^0.34.4", + "@vitest/ui": "^0.34.4", "ast-types": "^0.16.1", "changelogen": "^0.5.5", - "eslint": "^8.48.0", + "eslint": "^8.49.0", "eslint-config-unjs": "^0.2.1", "esno": "^0.17.0", "giget": "^1.1.2", @@ -62,7 +62,7 @@ "source-map": "npm:source-map-js@latest", "typescript": "^5.2.2", "unbuild": "^2.0.0", - "vitest": "^0.34.3" + "vitest": "^0.34.4" }, "resolutions": { "source-map": "npm:source-map-js@latest" @@ -76,7 +76,7 @@ "prettier -w" ] }, - "packageManager": "pnpm@8.7.4", + "packageManager": "pnpm@8.7.5", "pnpm": { "overrides": { "array-includes": "npm:@nolyfill/array-includes@latest", diff --git a/pnpm-lock.yaml b/pnpm-lock.yaml index 35eb696..2614437 100644 --- a/pnpm-lock.yaml +++ b/pnpm-lock.yaml @@ -26,24 +26,24 @@ importers: .: dependencies: '@babel/parser': - specifier: ^7.22.15 - version: 7.22.15 + specifier: ^7.22.16 + version: 7.22.16 '@babel/types': - specifier: ^7.22.15 - version: 7.22.15 + specifier: ^7.22.19 + version: 7.22.19 source-map-js: specifier: ^1.0.2 version: 1.0.2 devDependencies: '@types/node': - specifier: ^20.5.9 - version: 20.5.9 + specifier: ^20.6.0 + version: 20.6.0 '@vitest/coverage-v8': - specifier: ^0.34.3 - version: 0.34.3(vitest@0.34.3) + specifier: ^0.34.4 + version: 0.34.4(vitest@0.34.4) '@vitest/ui': - specifier: ^0.34.3 - version: 0.34.3(vitest@0.34.3) + specifier: ^0.34.4 + version: 0.34.4(vitest@0.34.4) ast-types: specifier: ^0.16.1 version: 0.16.1 @@ -51,11 +51,11 @@ importers: specifier: ^0.5.5 version: 0.5.5 eslint: - specifier: ^8.48.0 - version: 8.48.0 + specifier: ^8.49.0 + version: 8.49.0 eslint-config-unjs: specifier: ^0.2.1 - version: 0.2.1(eslint@8.48.0)(typescript@5.2.2) + version: 0.2.1(eslint@8.49.0)(typescript@5.2.2) esno: specifier: ^0.17.0 version: 0.17.0 @@ -87,8 +87,8 @@ importers: specifier: ^2.0.0 version: 2.0.0(typescript@5.2.2) vitest: - specifier: ^0.34.3 - version: 0.34.3(@vitest/ui@0.34.3) + specifier: ^0.34.4 + version: 0.34.4(@vitest/ui@0.34.4) packages: @@ -128,10 +128,10 @@ packages: '@babel/helper-compilation-targets': 7.22.15 '@babel/helper-module-transforms': 7.22.15(@babel/core@7.22.15) '@babel/helpers': 7.22.15 - '@babel/parser': 7.22.15 + '@babel/parser': 7.22.16 '@babel/template': 7.22.15 '@babel/traverse': 7.22.15 - '@babel/types': 7.22.15 + '@babel/types': 7.22.19 convert-source-map: 1.9.0 debug: 4.3.4 gensync: 1.0.0-beta.2 @@ -145,7 +145,7 @@ packages: resolution: {integrity: sha512-Zu9oWARBqeVOW0dZOjXc3JObrzuqothQ3y/n1kUtrjCoCPLkXUwMvOo/F/TCfoHMbWIFlWwpZtkZVb9ga4U2pA==} engines: {node: '>=6.9.0'} dependencies: - '@babel/types': 7.22.15 + '@babel/types': 7.22.19 '@jridgewell/gen-mapping': 0.3.2 '@jridgewell/trace-mapping': 0.3.17 jsesc: 2.5.2 @@ -172,21 +172,21 @@ packages: engines: {node: '>=6.9.0'} dependencies: '@babel/template': 7.22.15 - '@babel/types': 7.22.15 + '@babel/types': 7.22.19 dev: true /@babel/helper-hoist-variables@7.22.5: resolution: {integrity: sha512-wGjk9QZVzvknA6yKIUURb8zY3grXCcOZt+/7Wcy8O2uctxhplmUPkOdlgoNhmdVee2c92JXbf1xpMtVNbfoxRw==} engines: {node: '>=6.9.0'} dependencies: - '@babel/types': 7.22.15 + '@babel/types': 7.22.19 dev: true /@babel/helper-module-imports@7.22.15: resolution: {integrity: sha512-0pYVBnDKZO2fnSPCrgM/6WMc7eS20Fbok+0r88fp+YtWVLZrp4CkafFGIp+W0VKw4a22sgebPT99y+FDNMdP4w==} engines: {node: '>=6.9.0'} dependencies: - '@babel/types': 7.22.15 + '@babel/types': 7.22.19 dev: true /@babel/helper-module-transforms@7.22.15(@babel/core@7.22.15): @@ -207,14 +207,14 @@ packages: resolution: {integrity: sha512-n0H99E/K+Bika3++WNL17POvo4rKWZ7lZEp1Q+fStVbUi8nxPQEBOlTmCOxW/0JsS56SKKQ+ojAe2pHKJHN35w==} engines: {node: '>=6.9.0'} dependencies: - '@babel/types': 7.22.15 + '@babel/types': 7.22.19 dev: true /@babel/helper-split-export-declaration@7.22.6: resolution: {integrity: sha512-AsUnxuLhRYsisFiaJwvp1QF+I3KjD5FOxut14q/GzovUe6orHLesW2C7d754kRm53h5gqrz6sFl6sxc4BVtE/g==} engines: {node: '>=6.9.0'} dependencies: - '@babel/types': 7.22.15 + '@babel/types': 7.22.19 dev: true /@babel/helper-string-parser@7.22.5: @@ -224,6 +224,11 @@ packages: /@babel/helper-validator-identifier@7.22.15: resolution: {integrity: sha512-4E/F9IIEi8WR94324mbDUMo074YTheJmd7eZF5vITTeYchqAi6sYXRLHUVsmkdmY4QjfKTcB2jB7dVP3NaBElQ==} engines: {node: '>=6.9.0'} + dev: true + + /@babel/helper-validator-identifier@7.22.19: + resolution: {integrity: sha512-Tinq7ybnEPFFXhlYOYFiSjespWQk0dq2dRNAiMdRTOYQzEGqnnNyrTxPYHP5r6wGjlF1rFgABdDV0g8EwD6Qbg==} + engines: {node: '>=6.9.0'} /@babel/helper-validator-option@7.22.15: resolution: {integrity: sha512-bMn7RmyFjY/mdECUbgn9eoSY4vqvacUnS9i9vGAGttgFWesO6B4CYWA7XlpbWgBt71iv/hfbPlynohStqnu5hA==} @@ -236,7 +241,7 @@ packages: dependencies: '@babel/template': 7.22.15 '@babel/traverse': 7.22.15 - '@babel/types': 7.22.15 + '@babel/types': 7.22.19 transitivePeerDependencies: - supports-color dev: true @@ -251,12 +256,12 @@ packages: js-tokens: 4.0.0 dev: true - /@babel/parser@7.22.15: - resolution: {integrity: sha512-RWmQ/sklUN9BvGGpCDgSubhHWfAx24XDTDObup4ffvxaYsptOg2P3KG0j+1eWKLxpkX0j0uHxmpq2Z1SP/VhxA==} + /@babel/parser@7.22.16: + resolution: {integrity: sha512-+gPfKv8UWeKKeJTUxe59+OobVcrYHETCsORl61EmSkmgymguYk/X5bp7GuUIXaFsc6y++v8ZxPsLSSuujqDphA==} engines: {node: '>=6.0.0'} hasBin: true dependencies: - '@babel/types': 7.22.15 + '@babel/types': 7.22.19 /@babel/standalone@7.22.15: resolution: {integrity: sha512-8qE83Gths6g29KOpYF9uaFPOXa3oaFF1/88ejKwgkGAZRIkdmoR/jPIzVviAsWNSaZdIdMLWwKSoXpuk9iNGmw==} @@ -268,8 +273,8 @@ packages: engines: {node: '>=6.9.0'} dependencies: '@babel/code-frame': 7.22.13 - '@babel/parser': 7.22.15 - '@babel/types': 7.22.15 + '@babel/parser': 7.22.16 + '@babel/types': 7.22.19 dev: true /@babel/traverse@7.22.15: @@ -282,45 +287,45 @@ packages: '@babel/helper-function-name': 7.22.5 '@babel/helper-hoist-variables': 7.22.5 '@babel/helper-split-export-declaration': 7.22.6 - '@babel/parser': 7.22.15 - '@babel/types': 7.22.15 + '@babel/parser': 7.22.16 + '@babel/types': 7.22.19 debug: 4.3.4 globals: 11.12.0 transitivePeerDependencies: - supports-color dev: true - /@babel/types@7.22.15: - resolution: {integrity: sha512-X+NLXr0N8XXmN5ZsaQdm9U2SSC3UbIYq/doL++sueHOTisgZHoKaQtZxGuV2cUPQHMfjKEfg/g6oy7Hm6SKFtA==} + /@babel/types@7.22.19: + resolution: {integrity: sha512-P7LAw/LbojPzkgp5oznjE6tQEIWbp4PkkfrZDINTro9zgBRtI324/EYsiSI7lhPbpIQ+DCeR2NNmMWANGGfZsg==} engines: {node: '>=6.9.0'} dependencies: '@babel/helper-string-parser': 7.22.5 - '@babel/helper-validator-identifier': 7.22.15 + '@babel/helper-validator-identifier': 7.22.19 to-fast-properties: 2.0.0 /@bcoe/v8-coverage@0.2.3: resolution: {integrity: sha512-0hYQ8SB4Db5zvZB4axdMHGwEaQjkZzFjQiN9LVYvIFB2nSUHW9tYpxWriPrWDASIxiaXax83REcLxuSdnGPZtw==} dev: true - /@esbuild-kit/cjs-loader@2.4.2: - resolution: {integrity: sha512-BDXFbYOJzT/NBEtp71cvsrGPwGAMGRB/349rwKuoxNSiKjPraNNnlK6MIIabViCjqZugu6j+xeMDlEkWdHHJSg==} + /@esbuild-kit/cjs-loader@2.4.4: + resolution: {integrity: sha512-NfsJX4PdzhwSkfJukczyUiZGc7zNNWZcEAyqeISpDnn0PTfzMJR1aR8xAIPskBejIxBJbIgCCMzbaYa9SXepIg==} dependencies: - '@esbuild-kit/core-utils': 3.2.2 - get-tsconfig: 4.6.0 + '@esbuild-kit/core-utils': 3.3.1 + get-tsconfig: 4.7.0 dev: true - /@esbuild-kit/core-utils@3.2.2: - resolution: {integrity: sha512-Ub6LaRaAgF80dTSzUdXpFLM1pVDdmEVB9qb5iAzSpyDlX/mfJTFGOnZ516O05p5uWWteNviMKi4PAyEuRxI5gA==} + /@esbuild-kit/core-utils@3.3.1: + resolution: {integrity: sha512-zg2aeGLgbZ/U8AnHRD6y085BkRqlw7jOsqpI/AFaQg6FhcCRycAe+aFLibs9okVVYTMqWANDC76UVSzd3qBoOw==} dependencies: esbuild: 0.18.20 source-map-support: 0.5.21 dev: true - /@esbuild-kit/esm-loader@2.5.5: - resolution: {integrity: sha512-Qwfvj/qoPbClxCRNuac1Du01r9gvNOT+pMYtJDapfB1eoGN1YlJ1BixLyL9WVENRx5RXgNLdfYdx/CuswlGhMw==} + /@esbuild-kit/esm-loader@2.6.4: + resolution: {integrity: sha512-xcbyhN97xFFFEdDw6IC4EuzX9Ali3aV3cj2FIYragOQpbPM4X6QA2R5qaP3h7Tr0tuyI6dmJJdMw7oBHxBSXQA==} dependencies: - '@esbuild-kit/core-utils': 3.2.2 - get-tsconfig: 4.6.0 + '@esbuild-kit/core-utils': 3.3.1 + get-tsconfig: 4.7.0 dev: true /@esbuild/android-arm64@0.16.17: @@ -917,13 +922,13 @@ packages: dev: true optional: true - /@eslint-community/eslint-utils@4.4.0(eslint@8.48.0): + /@eslint-community/eslint-utils@4.4.0(eslint@8.49.0): resolution: {integrity: sha512-1/sA4dwrzBAyeUoQ6oxahHKmrZvsnLCg4RfxW3ZFGGmQkSNQPFNLV9CUEFQP1x9EYXHTo5p6xdhZM1Ne9p/AfA==} engines: {node: ^12.22.0 || ^14.17.0 || >=16.0.0} peerDependencies: eslint: ^6.0.0 || ^7.0.0 || >=8.0.0 dependencies: - eslint: 8.48.0 + eslint: 8.49.0 eslint-visitor-keys: 3.4.3 dev: true @@ -949,13 +954,13 @@ packages: - supports-color dev: true - /@eslint/js@8.48.0: - resolution: {integrity: sha512-ZSjtmelB7IJfWD2Fvb7+Z+ChTIKWq6kjda95fLcQKNS5aheVHn4IkfgRQE3sIIzTcSLwLcLZUD9UBt+V7+h+Pw==} + /@eslint/js@8.49.0: + resolution: {integrity: sha512-1S8uAY/MTJqVx0SC4epBq+N2yhuwtNwLbJYNZyhL2pO1ZVKn5HFXav5T41Ryzy9K9V7ZId2JB2oy/W4aCd9/2w==} engines: {node: ^12.22.0 || ^14.17.0 || >=16.0.0} dev: true - /@humanwhocodes/config-array@0.11.10: - resolution: {integrity: sha512-KVVjQmNUepDVGXNuoRRdmmEjruj0KfiGSbS8LVc12LMsWDQzRXJ0qdhN8L8uUigKpfEHRhlaQFY0ib1tnUbNeQ==} + /@humanwhocodes/config-array@0.11.11: + resolution: {integrity: sha512-N2brEuAadi0CcdeMXUkhbZB84eskAc8MEX1By6qEchoVywSgXPIjou4rYsl0V3Hj0ZnuGycGCjdNgockbzeWNA==} engines: {node: '>=10.10.0'} dependencies: '@humanwhocodes/object-schema': 1.2.1 @@ -1177,7 +1182,7 @@ packages: '@rollup/pluginutils': 5.0.4(rollup@3.29.0) commondir: 1.0.1 estree-walker: 2.0.2 - glob: 8.0.3 + glob: 8.1.0 is-reference: 1.2.1 magic-string: 0.27.0 rollup: 3.29.0 @@ -1273,8 +1278,8 @@ packages: resolution: {integrity: sha512-dRLjCWHYg4oaA77cxO64oO+7JwCwnIzkZPdrrC71jQmQtlhM556pwKo5bUzqvZndkVbeFLIIi+9TC40JNF5hNQ==} dev: true - /@types/node@20.5.9: - resolution: {integrity: sha512-PcGNd//40kHAS3sTlzKB9C9XL4K0sTup8nbG5lC14kzEteTNuAFh9u5nA0o5TWnSG2r/JNPRXFVcHJIIeRlmqQ==} + /@types/node@20.6.0: + resolution: {integrity: sha512-najjVq5KN2vsH2U/xyh2opaSEz6cZMR2SetLIlxlj08nOcmPOemJmUK2o4kUzfLqfrWE0PIrNeE16XhYDd3nqg==} dev: true /@types/normalize-package-data@2.4.1: @@ -1289,7 +1294,7 @@ packages: resolution: {integrity: sha512-21cFJr9z3g5dW8B0CVI9g2O9beqaThGQ6ZFBqHfwhzLDKUxaqTIy3vnfah/UPkfOiF2pLq+tGz+W8RyCskuslw==} dev: true - /@typescript-eslint/eslint-plugin@5.62.0(@typescript-eslint/parser@5.62.0)(eslint@8.48.0)(typescript@5.2.2): + /@typescript-eslint/eslint-plugin@5.62.0(@typescript-eslint/parser@5.62.0)(eslint@8.49.0)(typescript@5.2.2): resolution: {integrity: sha512-TiZzBSJja/LbhNPvk6yc0JrX9XqhQ0hdh6M2svYfsHGejaKFIAGd9MQ+ERIMzLGlN/kZoYIgdxFV0PuljTKXag==} engines: {node: ^12.22.0 || ^14.17.0 || >=16.0.0} peerDependencies: @@ -1301,12 +1306,12 @@ packages: optional: true dependencies: '@eslint-community/regexpp': 4.6.2 - '@typescript-eslint/parser': 5.62.0(eslint@8.48.0)(typescript@5.2.2) + '@typescript-eslint/parser': 5.62.0(eslint@8.49.0)(typescript@5.2.2) '@typescript-eslint/scope-manager': 5.62.0 - '@typescript-eslint/type-utils': 5.62.0(eslint@8.48.0)(typescript@5.2.2) - '@typescript-eslint/utils': 5.62.0(eslint@8.48.0)(typescript@5.2.2) + '@typescript-eslint/type-utils': 5.62.0(eslint@8.49.0)(typescript@5.2.2) + '@typescript-eslint/utils': 5.62.0(eslint@8.49.0)(typescript@5.2.2) debug: 4.3.4 - eslint: 8.48.0 + eslint: 8.49.0 graphemer: 1.4.0 ignore: 5.2.4 natural-compare-lite: 1.4.0 @@ -1317,7 +1322,7 @@ packages: - supports-color dev: true - /@typescript-eslint/parser@5.62.0(eslint@8.48.0)(typescript@5.2.2): + /@typescript-eslint/parser@5.62.0(eslint@8.49.0)(typescript@5.2.2): resolution: {integrity: sha512-VlJEV0fOQ7BExOsHYAGrgbEiZoi8D+Bl2+f6V2RrXerRSylnp+ZBHmPvaIa8cz0Ajx7WO7Z5RqfgYg7ED1nRhA==} engines: {node: ^12.22.0 || ^14.17.0 || >=16.0.0} peerDependencies: @@ -1331,7 +1336,7 @@ packages: '@typescript-eslint/types': 5.62.0 '@typescript-eslint/typescript-estree': 5.62.0(typescript@5.2.2) debug: 4.3.4 - eslint: 8.48.0 + eslint: 8.49.0 typescript: 5.2.2 transitivePeerDependencies: - supports-color @@ -1345,7 +1350,7 @@ packages: '@typescript-eslint/visitor-keys': 5.62.0 dev: true - /@typescript-eslint/type-utils@5.62.0(eslint@8.48.0)(typescript@5.2.2): + /@typescript-eslint/type-utils@5.62.0(eslint@8.49.0)(typescript@5.2.2): resolution: {integrity: sha512-xsSQreu+VnfbqQpW5vnCJdq1Z3Q0U31qiWmRhr98ONQmcp/yhiPJFPq8MXiJVLiksmOKSjIldZzkebzHuCGzew==} engines: {node: ^12.22.0 || ^14.17.0 || >=16.0.0} peerDependencies: @@ -1356,9 +1361,9 @@ packages: optional: true dependencies: '@typescript-eslint/typescript-estree': 5.62.0(typescript@5.2.2) - '@typescript-eslint/utils': 5.62.0(eslint@8.48.0)(typescript@5.2.2) + '@typescript-eslint/utils': 5.62.0(eslint@8.49.0)(typescript@5.2.2) debug: 4.3.4 - eslint: 8.48.0 + eslint: 8.49.0 tsutils: 3.21.0(typescript@5.2.2) typescript: 5.2.2 transitivePeerDependencies: @@ -1391,19 +1396,19 @@ packages: - supports-color dev: true - /@typescript-eslint/utils@5.62.0(eslint@8.48.0)(typescript@5.2.2): + /@typescript-eslint/utils@5.62.0(eslint@8.49.0)(typescript@5.2.2): resolution: {integrity: sha512-n8oxjeb5aIbPFEtmQxQYOLI0i9n5ySBEY/ZEHHZqKQSFnxio1rv6dthascc9dLuwrL0RC5mPCxB7vnAVGAYWAQ==} engines: {node: ^12.22.0 || ^14.17.0 || >=16.0.0} peerDependencies: eslint: ^6.0.0 || ^7.0.0 || ^8.0.0 dependencies: - '@eslint-community/eslint-utils': 4.4.0(eslint@8.48.0) + '@eslint-community/eslint-utils': 4.4.0(eslint@8.49.0) '@types/json-schema': 7.0.11 '@types/semver': 7.3.13 '@typescript-eslint/scope-manager': 5.62.0 '@typescript-eslint/types': 5.62.0 '@typescript-eslint/typescript-estree': 5.62.0(typescript@5.2.2) - eslint: 8.48.0 + eslint: 8.49.0 eslint-scope: 5.1.1 semver: 7.5.4 transitivePeerDependencies: @@ -1419,8 +1424,8 @@ packages: eslint-visitor-keys: 3.4.3 dev: true - /@vitest/coverage-v8@0.34.3(vitest@0.34.3): - resolution: {integrity: sha512-bNjP0RHe8UxdklCigZlk6FVCNbOiqVjWnpZJ1zKixpvb7YHSaZiN/w+mzpvXIoqyxyePzKC+L+G1oj7SB20PJw==} + /@vitest/coverage-v8@0.34.4(vitest@0.34.4): + resolution: {integrity: sha512-TZ5ghzhmg3COQqfBShL+zRQEInHmV9TSwghTdfkHpCTyTOr+rxo6x41vCNcVfWysWULtqtBVpY6YFNovxnESfA==} peerDependencies: vitest: '>=0.32.0 <1' dependencies: @@ -1430,63 +1435,63 @@ packages: istanbul-lib-report: 3.0.1 istanbul-lib-source-maps: 4.0.1 istanbul-reports: 3.1.5 - magic-string: 0.30.1 + magic-string: 0.30.3 picocolors: 1.0.0 - std-env: 3.3.3 + std-env: 3.4.3 test-exclude: 6.0.0 v8-to-istanbul: 9.1.0 - vitest: 0.34.3(@vitest/ui@0.34.3) + vitest: 0.34.4(@vitest/ui@0.34.4) transitivePeerDependencies: - supports-color dev: true - /@vitest/expect@0.34.3: - resolution: {integrity: sha512-F8MTXZUYRBVsYL1uoIft1HHWhwDbSzwAU9Zgh8S6WFC3YgVb4AnFV2GXO3P5Em8FjEYaZtTnQYoNwwBrlOMXgg==} + /@vitest/expect@0.34.4: + resolution: {integrity: sha512-XlMKX8HyYUqB8dsY8Xxrc64J2Qs9pKMt2Z8vFTL4mBWXJsg4yoALHzJfDWi8h5nkO4Zua4zjqtapQ/IluVkSnA==} dependencies: - '@vitest/spy': 0.34.3 - '@vitest/utils': 0.34.3 + '@vitest/spy': 0.34.4 + '@vitest/utils': 0.34.4 chai: 4.3.7 dev: true - /@vitest/runner@0.34.3: - resolution: {integrity: sha512-lYNq7N3vR57VMKMPLVvmJoiN4bqwzZ1euTW+XXYH5kzr3W/+xQG3b41xJn9ChJ3AhYOSoweu974S1V3qDcFESA==} + /@vitest/runner@0.34.4: + resolution: {integrity: sha512-hwwdB1StERqUls8oV8YcpmTIpVeJMe4WgYuDongVzixl5hlYLT2G8afhcdADeDeqCaAmZcSgLTLtqkjPQF7x+w==} dependencies: - '@vitest/utils': 0.34.3 + '@vitest/utils': 0.34.4 p-limit: 4.0.0 pathe: 1.1.1 dev: true - /@vitest/snapshot@0.34.3: - resolution: {integrity: sha512-QyPaE15DQwbnIBp/yNJ8lbvXTZxS00kRly0kfFgAD5EYmCbYcA+1EEyRalc93M0gosL/xHeg3lKAClIXYpmUiQ==} + /@vitest/snapshot@0.34.4: + resolution: {integrity: sha512-GCsh4coc3YUSL/o+BPUo7lHQbzpdttTxL6f4q0jRx2qVGoYz/cyTRDJHbnwks6TILi6560bVWoBpYC10PuTLHw==} dependencies: - magic-string: 0.30.1 + magic-string: 0.30.3 pathe: 1.1.1 pretty-format: 29.6.1 dev: true - /@vitest/spy@0.34.3: - resolution: {integrity: sha512-N1V0RFQ6AI7CPgzBq9kzjRdPIgThC340DGjdKdPSE8r86aUSmeliTUgkTqLSgtEwWWsGfBQ+UetZWhK0BgJmkQ==} + /@vitest/spy@0.34.4: + resolution: {integrity: sha512-PNU+fd7DUPgA3Ya924b1qKuQkonAW6hL7YUjkON3wmBwSTIlhOSpy04SJ0NrRsEbrXgMMj6Morh04BMf8k+w0g==} dependencies: tinyspy: 2.1.1 dev: true - /@vitest/ui@0.34.3(vitest@0.34.3): - resolution: {integrity: sha512-iNcOQ0xML9znOReiwpKJrTLSj5zFxmveD3VCxIJNqnsaMYpONSbSiiJLC1Y1dYlkmiHylp+ElNcUZYIMWdxRvA==} + /@vitest/ui@0.34.4(vitest@0.34.4): + resolution: {integrity: sha512-gz0m0r9ErFG32r+DRdwuLJpUDpbi+jrMcw9nJZAau48Fs4LDIBg561PvczvGqyYxzbyFU7vgkSnSlSDfK0d53w==} peerDependencies: vitest: '>=0.30.1 <1' dependencies: - '@vitest/utils': 0.34.3 + '@vitest/utils': 0.34.4 fast-glob: 3.3.1 fflate: 0.8.0 flatted: 3.2.7 pathe: 1.1.1 picocolors: 1.0.0 sirv: 2.0.3 - vitest: 0.34.3(@vitest/ui@0.34.3) + vitest: 0.34.4(@vitest/ui@0.34.4) dev: true - /@vitest/utils@0.34.3: - resolution: {integrity: sha512-kiSnzLG6m/tiT0XEl4U2H8JDBjFtwVlaE8I3QfGiMFR0QvnRDfYfdP3YvTBWM/6iJDAyaPY6yVQiCTUc7ZzTHA==} + /@vitest/utils@0.34.4: + resolution: {integrity: sha512-yR2+5CHhp/K4ySY0Qtd+CAL9f5Yh1aXrKfAT42bq6CtlGPh92jIDDDSg7ydlRow1CP+dys4TrOrbELOyNInHSg==} dependencies: diff-sequences: 29.4.3 loupe: 2.3.6 @@ -1690,7 +1695,7 @@ packages: defu: 6.1.2 dotenv: 16.3.1 giget: 1.1.2 - jiti: 1.18.2 + jiti: 1.19.3 mlly: 1.4.0 ohash: 1.1.2 pathe: 1.1.1 @@ -2141,16 +2146,16 @@ packages: engines: {node: '>=10'} dev: true - /eslint-config-prettier@8.8.0(eslint@8.48.0): + /eslint-config-prettier@8.8.0(eslint@8.49.0): resolution: {integrity: sha512-wLbQiFre3tdGgpDv67NQKnJuTlcUVYHas3k+DZCc2U2BadthoEY4B7hLPvAxaqdyOGCzuLfii2fqGph10va7oA==} hasBin: true peerDependencies: eslint: '>=7.0.0' dependencies: - eslint: 8.48.0 + eslint: 8.49.0 dev: true - /eslint-config-standard@17.1.0(eslint-plugin-import@2.27.5)(eslint-plugin-n@16.0.1)(eslint-plugin-promise@6.1.1)(eslint@8.48.0): + /eslint-config-standard@17.1.0(eslint-plugin-import@2.27.5)(eslint-plugin-n@16.0.1)(eslint-plugin-promise@6.1.1)(eslint@8.49.0): resolution: {integrity: sha512-IwHwmaBNtDK4zDHQukFDW5u/aTb8+meQWZvNFWkiGmbWjD6bqyuSSBxxXKkCftCUzc1zwCH2m/baCNDLGmuO5Q==} engines: {node: '>=12.0.0'} peerDependencies: @@ -2159,29 +2164,29 @@ packages: eslint-plugin-n: '^15.0.0 || ^16.0.0 ' eslint-plugin-promise: ^6.0.0 dependencies: - eslint: 8.48.0 - eslint-plugin-import: 2.27.5(@typescript-eslint/parser@5.62.0)(eslint-import-resolver-typescript@3.5.5)(eslint@8.48.0) - eslint-plugin-n: 16.0.1(eslint@8.48.0) - eslint-plugin-promise: 6.1.1(eslint@8.48.0) + eslint: 8.49.0 + eslint-plugin-import: 2.27.5(@typescript-eslint/parser@5.62.0)(eslint-import-resolver-typescript@3.5.5)(eslint@8.49.0) + eslint-plugin-n: 16.0.1(eslint@8.49.0) + eslint-plugin-promise: 6.1.1(eslint@8.49.0) dev: true - /eslint-config-unjs@0.2.1(eslint@8.48.0)(typescript@5.2.2): + /eslint-config-unjs@0.2.1(eslint@8.49.0)(typescript@5.2.2): resolution: {integrity: sha512-h17q+WR86glq8yLFuHfEnAFfbEYqXpJAppXc0e0fQz0gsotJQ14BZVrlvIThE2a+stWyh0VT73gbBPfosl2rVA==} peerDependencies: eslint: '*' typescript: '*' dependencies: - '@typescript-eslint/eslint-plugin': 5.62.0(@typescript-eslint/parser@5.62.0)(eslint@8.48.0)(typescript@5.2.2) - '@typescript-eslint/parser': 5.62.0(eslint@8.48.0)(typescript@5.2.2) - eslint: 8.48.0 - eslint-config-prettier: 8.8.0(eslint@8.48.0) - eslint-config-standard: 17.1.0(eslint-plugin-import@2.27.5)(eslint-plugin-n@16.0.1)(eslint-plugin-promise@6.1.1)(eslint@8.48.0) - eslint-import-resolver-typescript: 3.5.5(@typescript-eslint/parser@5.62.0)(eslint-plugin-import@2.27.5)(eslint@8.48.0) - eslint-plugin-import: 2.27.5(@typescript-eslint/parser@5.62.0)(eslint-import-resolver-typescript@3.5.5)(eslint@8.48.0) - eslint-plugin-n: 16.0.1(eslint@8.48.0) - eslint-plugin-node: 11.1.0(eslint@8.48.0) - eslint-plugin-promise: 6.1.1(eslint@8.48.0) - eslint-plugin-unicorn: 47.0.0(eslint@8.48.0) + '@typescript-eslint/eslint-plugin': 5.62.0(@typescript-eslint/parser@5.62.0)(eslint@8.49.0)(typescript@5.2.2) + '@typescript-eslint/parser': 5.62.0(eslint@8.49.0)(typescript@5.2.2) + eslint: 8.49.0 + eslint-config-prettier: 8.8.0(eslint@8.49.0) + eslint-config-standard: 17.1.0(eslint-plugin-import@2.27.5)(eslint-plugin-n@16.0.1)(eslint-plugin-promise@6.1.1)(eslint@8.49.0) + eslint-import-resolver-typescript: 3.5.5(@typescript-eslint/parser@5.62.0)(eslint-plugin-import@2.27.5)(eslint@8.49.0) + eslint-plugin-import: 2.27.5(@typescript-eslint/parser@5.62.0)(eslint-import-resolver-typescript@3.5.5)(eslint@8.49.0) + eslint-plugin-n: 16.0.1(eslint@8.49.0) + eslint-plugin-node: 11.1.0(eslint@8.49.0) + eslint-plugin-promise: 6.1.1(eslint@8.49.0) + eslint-plugin-unicorn: 47.0.0(eslint@8.49.0) typescript: 5.2.2 transitivePeerDependencies: - eslint-import-resolver-node @@ -2193,13 +2198,13 @@ packages: resolution: {integrity: sha512-gozW2blMLJCeFpBwugLTGyvVjNoeo1knonXAcatC6bjPBZitotxdWf7Gimr25N4c0AAOo4eOUfaG82IJPDpqCA==} dependencies: debug: 3.2.7 - is-core-module: 2.13.0 + is-core-module: 2.12.1 resolve: 1.22.2 transitivePeerDependencies: - supports-color dev: true - /eslint-import-resolver-typescript@3.5.5(@typescript-eslint/parser@5.62.0)(eslint-plugin-import@2.27.5)(eslint@8.48.0): + /eslint-import-resolver-typescript@3.5.5(@typescript-eslint/parser@5.62.0)(eslint-plugin-import@2.27.5)(eslint@8.49.0): resolution: {integrity: sha512-TdJqPHs2lW5J9Zpe17DZNQuDnox4xo2o+0tE7Pggain9Rbc19ik8kFtXdxZ250FVx2kF4vlt2RSf4qlUpG7bhw==} engines: {node: ^14.18.0 || >=16.0.0} peerDependencies: @@ -2208,12 +2213,12 @@ packages: dependencies: debug: 4.3.4 enhanced-resolve: 5.12.0 - eslint: 8.48.0 - eslint-module-utils: 2.7.4(@typescript-eslint/parser@5.62.0)(eslint-import-resolver-node@0.3.7)(eslint-import-resolver-typescript@3.5.5)(eslint@8.48.0) - eslint-plugin-import: 2.27.5(@typescript-eslint/parser@5.62.0)(eslint-import-resolver-typescript@3.5.5)(eslint@8.48.0) + eslint: 8.49.0 + eslint-module-utils: 2.7.4(@typescript-eslint/parser@5.62.0)(eslint-import-resolver-node@0.3.7)(eslint-import-resolver-typescript@3.5.5)(eslint@8.49.0) + eslint-plugin-import: 2.27.5(@typescript-eslint/parser@5.62.0)(eslint-import-resolver-typescript@3.5.5)(eslint@8.49.0) get-tsconfig: 4.6.0 - globby: 13.1.4 - is-core-module: 2.13.0 + globby: 13.2.2 + is-core-module: 2.12.1 is-glob: 4.0.3 synckit: 0.8.5 transitivePeerDependencies: @@ -2223,7 +2228,7 @@ packages: - supports-color dev: true - /eslint-module-utils@2.7.4(@typescript-eslint/parser@5.62.0)(eslint-import-resolver-node@0.3.7)(eslint-import-resolver-typescript@3.5.5)(eslint@8.48.0): + /eslint-module-utils@2.7.4(@typescript-eslint/parser@5.62.0)(eslint-import-resolver-node@0.3.7)(eslint-import-resolver-typescript@3.5.5)(eslint@8.49.0): resolution: {integrity: sha512-j4GT+rqzCoRKHwURX7pddtIPGySnX9Si/cgMI5ztrcqOPtk5dDEeZ34CQVPphnqkJytlc97Vuk05Um2mJ3gEQA==} engines: {node: '>=4'} peerDependencies: @@ -2244,38 +2249,38 @@ packages: eslint-import-resolver-webpack: optional: true dependencies: - '@typescript-eslint/parser': 5.62.0(eslint@8.48.0)(typescript@5.2.2) + '@typescript-eslint/parser': 5.62.0(eslint@8.49.0)(typescript@5.2.2) debug: 3.2.7 - eslint: 8.48.0 + eslint: 8.49.0 eslint-import-resolver-node: 0.3.7 - eslint-import-resolver-typescript: 3.5.5(@typescript-eslint/parser@5.62.0)(eslint-plugin-import@2.27.5)(eslint@8.48.0) + eslint-import-resolver-typescript: 3.5.5(@typescript-eslint/parser@5.62.0)(eslint-plugin-import@2.27.5)(eslint@8.49.0) transitivePeerDependencies: - supports-color dev: true - /eslint-plugin-es-x@7.2.0(eslint@8.48.0): + /eslint-plugin-es-x@7.2.0(eslint@8.49.0): resolution: {integrity: sha512-9dvv5CcvNjSJPqnS5uZkqb3xmbeqRLnvXKK7iI5+oK/yTusyc46zbBZKENGsOfojm/mKfszyZb+wNqNPAPeGXA==} engines: {node: ^14.18.0 || >=16.0.0} peerDependencies: eslint: '>=8' dependencies: - '@eslint-community/eslint-utils': 4.4.0(eslint@8.48.0) + '@eslint-community/eslint-utils': 4.4.0(eslint@8.49.0) '@eslint-community/regexpp': 4.6.2 - eslint: 8.48.0 + eslint: 8.49.0 dev: true - /eslint-plugin-es@3.0.1(eslint@8.48.0): + /eslint-plugin-es@3.0.1(eslint@8.49.0): resolution: {integrity: sha512-GUmAsJaN4Fc7Gbtl8uOBlayo2DqhwWvEzykMHSCZHU3XdJ+NSzzZcVhXh3VxX5icqQ+oQdIEawXX8xkR3mIFmQ==} engines: {node: '>=8.10.0'} peerDependencies: eslint: '>=4.19.1' dependencies: - eslint: 8.48.0 + eslint: 8.49.0 eslint-utils: 2.1.0 regexpp: 3.2.0 dev: true - /eslint-plugin-import@2.27.5(@typescript-eslint/parser@5.62.0)(eslint-import-resolver-typescript@3.5.5)(eslint@8.48.0): + /eslint-plugin-import@2.27.5(@typescript-eslint/parser@5.62.0)(eslint-import-resolver-typescript@3.5.5)(eslint@8.49.0): resolution: {integrity: sha512-LmEt3GVofgiGuiE+ORpnvP+kAm3h6MLZJ4Q5HCyHADofsb4VzXFsRiWj3c0OFiV+3DWFh0qg3v9gcPlfc3zRow==} engines: {node: '>=4'} peerDependencies: @@ -2285,22 +2290,22 @@ packages: '@typescript-eslint/parser': optional: true dependencies: - '@typescript-eslint/parser': 5.62.0(eslint@8.48.0)(typescript@5.2.2) + '@typescript-eslint/parser': 5.62.0(eslint@8.49.0)(typescript@5.2.2) array-includes: /@nolyfill/array-includes@1.0.21 array.prototype.flat: /@nolyfill/array.prototype.flat@1.0.21 array.prototype.flatmap: /@nolyfill/array.prototype.flatmap@1.0.21 debug: 3.2.7 doctrine: 2.1.0 - eslint: 8.48.0 + eslint: 8.49.0 eslint-import-resolver-node: 0.3.7 - eslint-module-utils: 2.7.4(@typescript-eslint/parser@5.62.0)(eslint-import-resolver-node@0.3.7)(eslint-import-resolver-typescript@3.5.5)(eslint@8.48.0) + eslint-module-utils: 2.7.4(@typescript-eslint/parser@5.62.0)(eslint-import-resolver-node@0.3.7)(eslint-import-resolver-typescript@3.5.5)(eslint@8.49.0) has: /@nolyfill/has@1.0.21 - is-core-module: 2.13.0 + is-core-module: 2.12.1 is-glob: 4.0.3 minimatch: 3.1.2 object.values: /@nolyfill/object.values@1.0.21 resolve: 1.22.2 - semver: 6.3.0 + semver: 6.3.1 tsconfig-paths: 3.14.1 transitivePeerDependencies: - eslint-import-resolver-typescript @@ -2308,58 +2313,58 @@ packages: - supports-color dev: true - /eslint-plugin-n@16.0.1(eslint@8.48.0): + /eslint-plugin-n@16.0.1(eslint@8.49.0): resolution: {integrity: sha512-CDmHegJN0OF3L5cz5tATH84RPQm9kG+Yx39wIqIwPR2C0uhBGMWfbbOtetR83PQjjidA5aXMu+LEFw1jaSwvTA==} engines: {node: '>=16.0.0'} peerDependencies: eslint: '>=7.0.0' dependencies: - '@eslint-community/eslint-utils': 4.4.0(eslint@8.48.0) + '@eslint-community/eslint-utils': 4.4.0(eslint@8.49.0) builtins: 5.0.1 - eslint: 8.48.0 - eslint-plugin-es-x: 7.2.0(eslint@8.48.0) + eslint: 8.49.0 + eslint-plugin-es-x: 7.2.0(eslint@8.49.0) ignore: 5.2.4 - is-core-module: 2.13.0 + is-core-module: 2.12.1 minimatch: 3.1.2 resolve: 1.22.2 semver: 7.5.4 dev: true - /eslint-plugin-node@11.1.0(eslint@8.48.0): + /eslint-plugin-node@11.1.0(eslint@8.49.0): resolution: {integrity: sha512-oUwtPJ1W0SKD0Tr+wqu92c5xuCeQqB3hSCHasn/ZgjFdA9iDGNkNf2Zi9ztY7X+hNuMib23LNGRm6+uN+KLE3g==} engines: {node: '>=8.10.0'} peerDependencies: eslint: '>=5.16.0' dependencies: - eslint: 8.48.0 - eslint-plugin-es: 3.0.1(eslint@8.48.0) + eslint: 8.49.0 + eslint-plugin-es: 3.0.1(eslint@8.49.0) eslint-utils: 2.1.0 ignore: 5.2.4 minimatch: 3.1.2 resolve: 1.22.2 - semver: 6.3.0 + semver: 6.3.1 dev: true - /eslint-plugin-promise@6.1.1(eslint@8.48.0): + /eslint-plugin-promise@6.1.1(eslint@8.49.0): resolution: {integrity: sha512-tjqWDwVZQo7UIPMeDReOpUgHCmCiH+ePnVT+5zVapL0uuHnegBUs2smM13CzOs2Xb5+MHMRFTs9v24yjba4Oig==} engines: {node: ^12.22.0 || ^14.17.0 || >=16.0.0} peerDependencies: eslint: ^7.0.0 || ^8.0.0 dependencies: - eslint: 8.48.0 + eslint: 8.49.0 dev: true - /eslint-plugin-unicorn@47.0.0(eslint@8.48.0): + /eslint-plugin-unicorn@47.0.0(eslint@8.49.0): resolution: {integrity: sha512-ivB3bKk7fDIeWOUmmMm9o3Ax9zbMz1Bsza/R2qm46ufw4T6VBFBaJIR1uN3pCKSmSXm8/9Nri8V+iUut1NhQGA==} engines: {node: '>=16'} peerDependencies: eslint: '>=8.38.0' dependencies: '@babel/helper-validator-identifier': 7.22.15 - '@eslint-community/eslint-utils': 4.4.0(eslint@8.48.0) + '@eslint-community/eslint-utils': 4.4.0(eslint@8.49.0) ci-info: 3.8.0 clean-regexp: 1.0.0 - eslint: 8.48.0 + eslint: 8.49.0 esquery: 1.5.0 indent-string: 4.0.0 is-builtin-module: 3.2.1 @@ -2407,16 +2412,16 @@ packages: engines: {node: ^12.22.0 || ^14.17.0 || >=16.0.0} dev: true - /eslint@8.48.0: - resolution: {integrity: sha512-sb6DLeIuRXxeM1YljSe1KEx9/YYeZFQWcV8Rq9HfigmdDEugjLEVEa1ozDjL6YDjBpQHPJxJzze+alxi4T3OLg==} + /eslint@8.49.0: + resolution: {integrity: sha512-jw03ENfm6VJI0jA9U+8H5zfl5b+FvuU3YYvZRdZHOlU2ggJkxrlkJH4HcDrZpj6YwD8kuYqvQM8LyesoazrSOQ==} engines: {node: ^12.22.0 || ^14.17.0 || >=16.0.0} hasBin: true dependencies: - '@eslint-community/eslint-utils': 4.4.0(eslint@8.48.0) + '@eslint-community/eslint-utils': 4.4.0(eslint@8.49.0) '@eslint-community/regexpp': 4.6.2 '@eslint/eslintrc': 2.1.2 - '@eslint/js': 8.48.0 - '@humanwhocodes/config-array': 0.11.10 + '@eslint/js': 8.49.0 + '@humanwhocodes/config-array': 0.11.11 '@humanwhocodes/module-importer': 1.0.1 '@nodelib/fs.walk': 1.2.8 ajv: 6.12.6 @@ -2457,7 +2462,7 @@ packages: resolution: {integrity: sha512-w78cQGlptQfsBYfootUCitsKS+MD74uR5L6kNsvwVkJsfzEepIafbvWsx2xK4rcFP4IUftt4F6J8EhagUxX+Bg==} hasBin: true dependencies: - tsx: 3.12.8 + tsx: 3.12.10 dev: true /espree@9.6.1: @@ -2704,6 +2709,12 @@ packages: resolve-pkg-maps: 1.0.0 dev: true + /get-tsconfig@4.7.0: + resolution: {integrity: sha512-pmjiZ7xtB8URYm74PlGJozDNyhvsVLUcpBa8DZBG3bWHwaHa9bPiRpiSfovw+fjhwONSCWKRyk+JQHEGZmMrzw==} + dependencies: + resolve-pkg-maps: 1.0.0 + dev: true + /giget@1.1.2: resolution: {integrity: sha512-HsLoS07HiQ5oqvObOI+Qb2tyZH4Gj5nYGfF9qQcZNrPw+uEFhdXtgJr01aO2pWadGHucajYDLxxbtQkm97ON2A==} hasBin: true @@ -2744,8 +2755,8 @@ packages: path-is-absolute: 1.0.1 dev: true - /glob@8.0.3: - resolution: {integrity: sha512-ull455NHSHI/Y1FqGaaYFaLGkNMMJbavMrEGFXG/PGrg6y7sutWHUHrz6gy6WEBH6akM1M414dWKCNs+IhKdiQ==} + /glob@8.1.0: + resolution: {integrity: sha512-r8hpEjiQEYlF2QU0df3dS+nxxSIreXQS1qRhMJM0Q5NDdR386C7jb7Hwwod8Fgiuex+k0GFjgft18yvxm5XoCQ==} engines: {node: '>=12'} dependencies: fs.realpath: 1.0.0 @@ -2783,17 +2794,6 @@ packages: slash: 3.0.0 dev: true - /globby@13.1.4: - resolution: {integrity: sha512-iui/IiiW+QrJ1X1hKH5qwlMQyv34wJAYwH1vrf8b9kBA4sNiif3gKsMHa+BrdnOpEudWjpotfa7LrTzB1ERS/g==} - engines: {node: ^12.20.0 || ^14.13.1 || >=16.0.0} - dependencies: - dir-glob: 3.0.1 - fast-glob: 3.3.1 - ignore: 5.2.4 - merge2: 1.4.1 - slash: 4.0.0 - dev: true - /globby@13.2.2: resolution: {integrity: sha512-Y1zNGV+pzQdh7H39l9zgB4PJqjRNqydvdYCDG4HFXM4XuvSaQQlEc91IU1yALL8gUTDomgBAfz3XJdmUS+oo0w==} engines: {node: ^12.20.0 || ^14.13.1 || >=16.0.0} @@ -2922,8 +2922,8 @@ packages: engines: {node: '>= 0.4'} dev: true - /is-core-module@2.13.0: - resolution: {integrity: sha512-Z7dk6Qo8pOCp3l4tsX2C5ZVas4V+UxwQodwZhLopL91TX8UyyHEXafPcyoeeWuLrwzHcr3igO78wNLwHJHsMCQ==} + /is-core-module@2.12.1: + resolution: {integrity: sha512-Q4ZuBAe2FUsKtyQJoQHlvP8OvBERxO3jEmy1I7hcRXcJBGGHFh/aJBswbXuS9sgrDH2QUO8ilkwNPHvHMd8clg==} dependencies: has: /@nolyfill/has@1.0.21 dev: true @@ -3058,11 +3058,6 @@ packages: istanbul-lib-report: 3.0.1 dev: true - /jiti@1.18.2: - resolution: {integrity: sha512-QAdOptna2NYiSSpv0O/BwoHBSmz4YhpzJHyi+fnMRTXFjp7B8i/YG5Z8IfusxB1ufjcD2Sre1F3R+nX3fvy7gg==} - hasBin: true - dev: true - /jiti@1.19.3: resolution: {integrity: sha512-5eEbBDQT/jF1xg6l36P+mWGGoH9Spuy0PCdSr2dtWRDGC6ph/w9ZCL4lmESW8f8F7MwT3XKescfP0wnZWAKL9w==} hasBin: true @@ -3252,13 +3247,6 @@ packages: '@jridgewell/sourcemap-codec': 1.4.15 dev: true - /magic-string@0.30.1: - resolution: {integrity: sha512-mbVKXPmS0z0G4XqFDCTllmDQ6coZzn94aMlb0o/A4HEHJCKcanlDZwYJgwnkmgD3jyWhUgj9VsPrfd972yPffA==} - engines: {node: '>=12'} - dependencies: - '@jridgewell/sourcemap-codec': 1.4.15 - dev: true - /magic-string@0.30.3: resolution: {integrity: sha512-B7xGbll2fG/VjP+SWg4sX3JynwIU0mjoTc6MPpKNuIvftk6u6vqhDnk1R80b8C2GBR6ywqy+1DcKBrevBg+bmw==} engines: {node: '>=12'} @@ -3760,7 +3748,7 @@ packages: resolution: {integrity: sha512-Sb+mjNHOULsBv818T40qSPeRiuWLyaGMa5ewydRLFimneixmVy2zdivRl+AF6jaYPC8ERxGDmFSiqui6SfPd+g==} hasBin: true dependencies: - is-core-module: 2.13.0 + is-core-module: 2.12.1 path-parse: 1.0.7 supports-preserve-symlinks-flag: 1.0.0 dev: true @@ -3803,14 +3791,6 @@ packages: '@babel/code-frame': 7.22.13 dev: true - /rollup@3.20.2: - resolution: {integrity: sha512-3zwkBQl7Ai7MFYQE0y1MeQ15+9jsi7XxfrqwTb/9EK8D9C9+//EBR4M+CuA1KODRaNbFez/lWxA5vhEGZp4MUg==} - engines: {node: '>=14.18.0', npm: '>=8.0.0'} - hasBin: true - optionalDependencies: - fsevents: 2.3.2 - dev: true - /rollup@3.29.0: resolution: {integrity: sha512-nszM8DINnx1vSS+TpbWKMkxem0CDWk3cSit/WWCBVs9/JZ1I/XLwOsiUglYuYReaeWWSsW9kge5zE5NZtf/a4w==} engines: {node: '>=14.18.0', npm: '>=8.0.0'} @@ -3847,11 +3827,6 @@ packages: hasBin: true dev: true - /semver@6.3.0: - resolution: {integrity: sha512-b39TBaTSfV6yBrapU89p5fKekE2m/NwnDocOVruQFS1/veMgdzuPcnOM34M6CwxW8jH/lxEa5rBoDeUwu5HHTw==} - hasBin: true - dev: true - /semver@6.3.1: resolution: {integrity: sha512-BR7VvDCVHO+q2xBEWskxS6DJE1qRnb7DxzUrogb71CWoSficBxYsiAGd+Kl0mmq/MprG9yArRkyrQxTO6XjMzA==} hasBin: true @@ -3965,10 +3940,6 @@ packages: resolution: {integrity: sha512-1XMJE5fQo1jGH6Y/7ebnwPOBEkIEnT4QF32d5R1+VXdXveM0IBMJt8zfaxX1P3QhVwrYe+576+jkANtSS2mBbw==} dev: true - /std-env@3.3.3: - resolution: {integrity: sha512-Rz6yejtVyWnVjC1RFvNmYL10kgjC49EOghxWn0RFqlCHGFpQx+Xe7yW3I4ceK1SGrWIGMjD5Kbue8W/udkbMJg==} - dev: true - /std-env@3.4.3: resolution: {integrity: sha512-f9aPhy8fYBuMN+sNfakZV18U39PbalgjXG3lLB9WkaYTxijru61wb57V9wxxNthXM5Sd88ETBWi29qLAsHO52Q==} dev: true @@ -4161,13 +4132,13 @@ packages: typescript: 5.2.2 dev: true - /tsx@3.12.8: - resolution: {integrity: sha512-Lt9KYaRGF023tlLInPj8rgHwsZU8qWLBj4iRXNWxTfjIkU7canGL806AqKear1j722plHuiYNcL2ZCo6uS9UJA==} + /tsx@3.12.10: + resolution: {integrity: sha512-2+46h4xvUt1aLDNvk5YBT8Uzw+b7BolGbn7iSMucYqCXZiDc+1IMghLVdw8kKjING32JFOeO+Am9posvjkeclA==} hasBin: true dependencies: - '@esbuild-kit/cjs-loader': 2.4.2 - '@esbuild-kit/core-utils': 3.2.2 - '@esbuild-kit/esm-loader': 2.5.5 + '@esbuild-kit/cjs-loader': 2.4.4 + '@esbuild-kit/core-utils': 3.3.1 + '@esbuild-kit/esm-loader': 2.6.4 optionalDependencies: fsevents: 2.3.2 dev: true @@ -4269,7 +4240,7 @@ packages: dependencies: '@babel/core': 7.22.15 '@babel/standalone': 7.22.15 - '@babel/types': 7.22.15 + '@babel/types': 7.22.19 defu: 6.1.2 jiti: 1.19.3 mri: 1.2.0 @@ -4321,8 +4292,8 @@ packages: spdx-expression-parse: 3.0.1 dev: true - /vite-node@0.34.3(@types/node@20.5.9): - resolution: {integrity: sha512-+0TzJf1g0tYXj6tR2vEyiA42OPq68QkRZCu/ERSo2PtsDJfBpDyEfuKbRvLmZqi/CgC7SCBtyC+WjTGNMRIaig==} + /vite-node@0.34.4(@types/node@20.6.0): + resolution: {integrity: sha512-ho8HtiLc+nsmbwZMw8SlghESEE3KxJNp04F/jPUCLVvaURwt0d+r9LxEqCX5hvrrOQ0GSyxbYr5ZfRYhQ0yVKQ==} engines: {node: '>=v14.18.0'} hasBin: true dependencies: @@ -4331,7 +4302,7 @@ packages: mlly: 1.4.0 pathe: 1.1.1 picocolors: 1.0.0 - vite: 4.1.1(@types/node@20.5.9) + vite: 4.1.1(@types/node@20.6.0) transitivePeerDependencies: - '@types/node' - less @@ -4342,7 +4313,7 @@ packages: - terser dev: true - /vite@4.1.1(@types/node@20.5.9): + /vite@4.1.1(@types/node@20.6.0): resolution: {integrity: sha512-LM9WWea8vsxhr782r9ntg+bhSFS06FJgCvvB0+8hf8UWtvaiDagKYWXndjfX6kGl74keHJUcpzrQliDXZlF5yg==} engines: {node: ^14.18.0 || >=16.0.0} hasBin: true @@ -4367,17 +4338,17 @@ packages: terser: optional: true dependencies: - '@types/node': 20.5.9 + '@types/node': 20.6.0 esbuild: 0.16.17 postcss: 8.4.21 resolve: 1.22.2 - rollup: 3.20.2 + rollup: 3.29.0 optionalDependencies: fsevents: 2.3.2 dev: true - /vitest@0.34.3(@vitest/ui@0.34.3): - resolution: {integrity: sha512-7+VA5Iw4S3USYk+qwPxHl8plCMhA5rtfwMjgoQXMT7rO5ldWcdsdo3U1QD289JgglGK4WeOzgoLTsGFu6VISyQ==} + /vitest@0.34.4(@vitest/ui@0.34.4): + resolution: {integrity: sha512-SE/laOsB6995QlbSE6BtkpXDeVNLJc1u2LHRG/OpnN4RsRzM3GQm4nm3PQCK5OBtrsUqnhzLdnT7se3aeNGdlw==} engines: {node: '>=v14.18.0'} hasBin: true peerDependencies: @@ -4409,28 +4380,28 @@ packages: dependencies: '@types/chai': 4.3.5 '@types/chai-subset': 1.3.3 - '@types/node': 20.5.9 - '@vitest/expect': 0.34.3 - '@vitest/runner': 0.34.3 - '@vitest/snapshot': 0.34.3 - '@vitest/spy': 0.34.3 - '@vitest/ui': 0.34.3(vitest@0.34.3) - '@vitest/utils': 0.34.3 + '@types/node': 20.6.0 + '@vitest/expect': 0.34.4 + '@vitest/runner': 0.34.4 + '@vitest/snapshot': 0.34.4 + '@vitest/spy': 0.34.4 + '@vitest/ui': 0.34.4(vitest@0.34.4) + '@vitest/utils': 0.34.4 acorn: 8.10.0 acorn-walk: 8.2.0 cac: 6.7.14 chai: 4.3.7 debug: 4.3.4 local-pkg: 0.4.3 - magic-string: 0.30.1 + magic-string: 0.30.3 pathe: 1.1.1 picocolors: 1.0.0 - std-env: 3.3.3 + std-env: 3.4.3 strip-literal: 1.0.1 tinybench: 2.5.0 tinypool: 0.7.0 - vite: 4.1.1(@types/node@20.5.9) - vite-node: 0.34.3(@types/node@20.5.9) + vite: 4.1.1(@types/node@20.6.0) + vite-node: 0.34.4(@types/node@20.6.0) why-is-node-running: 2.2.2 transitivePeerDependencies: - less diff --git a/src/helpers/config.ts b/src/helpers/config.ts index 71be36a..1e72497 100644 --- a/src/helpers/config.ts +++ b/src/helpers/config.ts @@ -46,9 +46,13 @@ export function getConfigFromVariableDeclaration( declaration.id.name === configDecalarationId && declaration.init ) { - const init = declaration.init; + const init = + declaration.init.type === "TSSatisfiesExpression" + ? declaration.init.expression + : declaration.init; - const configExpression = parseExpression(generateCode(init).code); + const code = generateCode(init).code; + const configExpression = parseExpression(code); return { declaration, diff --git a/src/helpers/vite.ts b/src/helpers/vite.ts index 1b51eb8..297bd2a 100644 --- a/src/helpers/vite.ts +++ b/src/helpers/vite.ts @@ -135,6 +135,23 @@ function insertPluginIntoVariableDeclarationConfig( declaration.init = generateCode( builders.functionCall(declaration.init.callee.name, configObject), ).code; + } else if (declaration.init.type === "TSSatisfiesExpression") { + if (declaration.init.expression.type === "ObjectExpression") { + // @ts-ignore this works despite the type error because of recast + declaration.init.expression = generateCode(configObject).code; + } + if ( + declaration.init.expression.type === "CallExpression" && + declaration.init.expression.callee.type === "Identifier" + ) { + // @ts-ignore this works despite the type error because of recast + declaration.init.expression = generateCode( + builders.functionCall( + declaration.init.expression.callee.name, + configObject, + ), + ).code; + } } } } diff --git a/test/array.test.ts b/test/array.test.ts index 5e20804..f9b40a9 100644 --- a/test/array.test.ts +++ b/test/array.test.ts @@ -1,6 +1,6 @@ import { describe, expect, it } from "vitest"; -import { parseModule } from "magicast"; import { generate } from "./_utils"; +import { parseModule } from "magicast"; describe("array", () => { it("array operations", async () => { diff --git a/test/builders/expression.test.ts b/test/builders/expression.test.ts index 9f24089..153262d 100644 --- a/test/builders/expression.test.ts +++ b/test/builders/expression.test.ts @@ -1,6 +1,6 @@ import { describe, expect, it } from "vitest"; -import { builders, parseModule } from "magicast"; import { generate } from "../_utils"; +import { builders, parseModule } from "magicast"; describe("builders/expression", () => { it("new expression", async () => { diff --git a/test/builders/function-call.test.ts b/test/builders/function-call.test.ts index 3f83b7f..587a834 100644 --- a/test/builders/function-call.test.ts +++ b/test/builders/function-call.test.ts @@ -1,6 +1,6 @@ import { describe, expect, it } from "vitest"; -import { builders, parseModule } from "magicast"; import { generate } from "../_utils"; +import { builders, parseModule } from "magicast"; describe("builders/functionCall", () => { it("new", async () => { diff --git a/test/builders/raw.test.ts b/test/builders/raw.test.ts index 5f3d25f..bf89a86 100644 --- a/test/builders/raw.test.ts +++ b/test/builders/raw.test.ts @@ -1,6 +1,6 @@ import { describe, expect, it } from "vitest"; -import { builders, parseModule } from "magicast"; import { generate } from "../_utils"; +import { builders, parseModule } from "magicast"; describe("builders/raw", () => { it("object", async () => { diff --git a/test/errors.test.ts b/test/errors.test.ts index 1e865da..e15d53d 100644 --- a/test/errors.test.ts +++ b/test/errors.test.ts @@ -1,6 +1,6 @@ import { expect, describe, it } from "vitest"; -import { parseExpression, parseModule } from "magicast"; import { generate } from "./_utils"; +import { parseExpression, parseModule } from "magicast"; describe("errors", () => { it("ternary", () => { diff --git a/test/exports.test.ts b/test/exports.test.ts index 69d8ae8..fe9f301 100644 --- a/test/exports.test.ts +++ b/test/exports.test.ts @@ -1,6 +1,6 @@ import { expect, it, describe } from "vitest"; -import { parseModule } from "magicast"; import { generate } from "./_utils"; +import { parseModule } from "magicast"; describe("exports", () => { it("manipulate exports", async () => { diff --git a/test/function-call.test.ts b/test/function-call.test.ts index fa467d4..80c2fac 100644 --- a/test/function-call.test.ts +++ b/test/function-call.test.ts @@ -1,6 +1,6 @@ import { describe, expect, it } from "vitest"; -import { builders, parseModule, ProxifiedModule } from "magicast"; import { generate } from "./_utils"; +import { builders, parseModule, ProxifiedModule } from "magicast"; describe("function-calls", () => { it("function wrapper", async () => { diff --git a/test/general.test.ts b/test/general.test.ts index 8aa5af5..ec69a0d 100644 --- a/test/general.test.ts +++ b/test/general.test.ts @@ -1,6 +1,6 @@ import { expect, it, describe } from "vitest"; -import { generateCode, parseModule, parseExpression } from "magicast"; import { generate } from "./_utils"; +import { generateCode, parseModule, parseExpression } from "magicast"; describe("general", () => { it("basic object and array", async () => { diff --git a/test/helpers/nuxt.test.ts b/test/helpers/nuxt.test.ts index 810614a..4fc6f96 100644 --- a/test/helpers/nuxt.test.ts +++ b/test/helpers/nuxt.test.ts @@ -1,6 +1,6 @@ import { it, describe, expect } from "vitest"; -import { parseModule } from "magicast"; import { generate } from "../_utils"; +import { parseModule } from "magicast"; import { addNuxtModule } from "magicast/helpers"; describe("helpers > nuxt", () => { diff --git a/test/helpers/vite.test.ts b/test/helpers/vite.test.ts index d0a13bf..1e51d63 100644 --- a/test/helpers/vite.test.ts +++ b/test/helpers/vite.test.ts @@ -1,6 +1,6 @@ import { it, describe, expect } from "vitest"; -import { parseModule } from "magicast"; import { generate } from "../_utils"; +import { parseModule } from "magicast"; import { addVitePlugin, updateVitePluginConfig } from "magicast/helpers"; describe("helpers > vite", () => { @@ -181,4 +181,76 @@ export default defineConfig({ export default myConfig;" `); }); + + it("handles default export from identifier (object with satisfies)", async () => { + const code = ` + import { somePlugin1, somePlugin2 } from 'some-module' + + import type { UserConfig } from 'vite'; + + const myConfig = { + plugins: [somePlugin1(), somePlugin2()] + } satisfies UserConfig; + + export default myConfig; + `; + + const mod = parseModule(code); + + addVitePlugin(mod, { + index: 1, + from: "vite-plugin-pwa", + imported: "VitePWA", + constructor: "VitePWA", + }); + + expect(await generate(mod)).toMatchInlineSnapshot(` + "import { VitePWA } from \\"vite-plugin-pwa\\"; + import { somePlugin1, somePlugin2 } from \\"some-module\\"; + + import type { UserConfig } from \\"vite\\"; + + const myConfig = { + plugins: [somePlugin1(), VitePWA(), somePlugin2()], + } satisfies UserConfig; + + export default myConfig;" + `); + }); + + it("handles default export from identifier (function with satisfies)", async () => { + const code = ` + import { somePlugin1, somePlugin2 } from 'some-module' + + import type { UserConfig } from 'vite'; + + const myConfig = defineConfig({ + plugins: [somePlugin1(), somePlugin2()] + }) satisfies UserConfig; + + export default myConfig; + `; + + const mod = parseModule(code); + + addVitePlugin(mod, { + index: 1, + from: "vite-plugin-pwa", + imported: "VitePWA", + constructor: "VitePWA", + }); + + expect(await generate(mod)).toMatchInlineSnapshot(` + "import { VitePWA } from \\"vite-plugin-pwa\\"; + import { somePlugin1, somePlugin2 } from \\"some-module\\"; + + import type { UserConfig } from \\"vite\\"; + + const myConfig = defineConfig({ + plugins: [somePlugin1(), VitePWA(), somePlugin2()], + }) satisfies UserConfig; + + export default myConfig;" + `); + }); }); diff --git a/test/imports.test.ts b/test/imports.test.ts index caef742..a116e4f 100644 --- a/test/imports.test.ts +++ b/test/imports.test.ts @@ -1,6 +1,6 @@ import { expect, it, describe } from "vitest"; -import { parseModule } from "magicast"; import { generate } from "./_utils"; +import { parseModule } from "magicast"; describe("imports", () => { it("manipulate imports", async () => {