diff --git a/.github/workflows/test-release.yml b/.github/workflows/test-release.yml index d667dc421..6a8f68e09 100644 --- a/.github/workflows/test-release.yml +++ b/.github/workflows/test-release.yml @@ -23,6 +23,7 @@ jobs: pnpm run-all-checks pnpm clean pnpm build + pnpm attw pnpm test:build e2e: runs-on: ubuntu-latest diff --git a/_internal/package.json b/_internal/package.json index 76da6864a..5f296295d 100644 --- a/_internal/package.json +++ b/_internal/package.json @@ -3,7 +3,6 @@ "module": "./dist/index.esm.js", "types": "./dist/index.d.ts", "exports": { - "types": "./dist/index.d.ts", "react-server": "./dist/react-server.mjs", "import": "./dist/index.mjs", "module": "./dist/index.esm.js", diff --git a/_internal/src/types.ts b/_internal/src/types.ts index 5db1b6679..385dfbf66 100644 --- a/_internal/src/types.ts +++ b/_internal/src/types.ts @@ -1,5 +1,4 @@ import type * as revalidateEvents from './constants' -import type { defaultConfig } from './utils/config' export type GlobalState = [ Record, // EVENT_REVALIDATORS @@ -293,8 +292,7 @@ export type Middleware = ( ) => ( key: Key, fetcher: BareFetcher | null, - config: typeof defaultConfig & - SWRConfiguration> + config: SWRConfiguration> ) => SWRResponse type ArgumentsTuple = [any, ...unknown[]] | readonly [any, ...unknown[]] diff --git a/core/package.json b/core/package.json index e706c484e..568577875 100644 --- a/core/package.json +++ b/core/package.json @@ -3,7 +3,6 @@ "module": "./dist/index.esm.js", "types": "./dist/index.d.ts", "exports": { - "types": "./dist/index.d.ts", "react-server": "./dist/react-server.mjs", "import": "./dist/index.mjs", "module": "./dist/index.esm.js", diff --git a/core/src/index.ts b/core/src/index.ts index d7fc5c387..c121fb34c 100644 --- a/core/src/index.ts +++ b/core/src/index.ts @@ -4,7 +4,8 @@ import 'client-only' import useSWR from './use-swr' export default useSWR // Core APIs -export { SWRConfig, unstable_serialize } from './use-swr' +export { SWRConfig } from './use-swr' +export { unstable_serialize } from './serialize' export { useSWRConfig } from 'swr/_internal' export { mutate } from 'swr/_internal' export { preload } from 'swr/_internal' diff --git a/core/src/serialize.ts b/core/src/serialize.ts index aabf8ec0e..98e0d86d7 100644 --- a/core/src/serialize.ts +++ b/core/src/serialize.ts @@ -1,4 +1,4 @@ -import type { Key } from 'swr' +import type { Key } from 'swr/_internal' import { serialize } from 'swr/_internal' export const unstable_serialize = (key: Key) => serialize(key)[0] diff --git a/immutable/package.json b/immutable/package.json index 1f30b94f3..67883a9e9 100644 --- a/immutable/package.json +++ b/immutable/package.json @@ -3,7 +3,6 @@ "module": "./dist/index.esm.js", "types": "./dist/index.d.ts", "exports": { - "types": "./dist/index.d.ts", "import": "./dist/index.mjs", "module": "./dist/index.esm.js", "require": "./dist/index.js" diff --git a/infinite/package.json b/infinite/package.json index 2c8982424..86a7c70c3 100644 --- a/infinite/package.json +++ b/infinite/package.json @@ -3,7 +3,6 @@ "module": "./dist/index.esm.js", "types": "./dist/index.d.ts", "exports": { - "types": "./dist/index.d.ts", "react-server": "./dist/react-server.mjs", "import": "./dist/index.mjs", "module": "./dist/index.esm.js", diff --git a/mutation/package.json b/mutation/package.json index 1f30b94f3..67883a9e9 100644 --- a/mutation/package.json +++ b/mutation/package.json @@ -3,7 +3,6 @@ "module": "./dist/index.esm.js", "types": "./dist/index.d.ts", "exports": { - "types": "./dist/index.d.ts", "import": "./dist/index.mjs", "module": "./dist/index.esm.js", "require": "./dist/index.js" diff --git a/package.json b/package.json index f8527d5d0..4761d04d3 100644 --- a/package.json +++ b/package.json @@ -14,42 +14,52 @@ "main": "./core/dist/index.js", "module": "./core/dist/index.esm.js", "types": "./core/dist/index.d.ts", + "typesVersions": { + "*": { + "infinite": [ + "./infinite/dist/index.d.ts" + ], + "immutable": [ + "./immutable/dist/index.d.ts" + ], + "mutation": [ + "./mutation/dist/index.d.ts" + ], + "subscription": [ + "./subscription/dist/index.d.ts" + ] + } + }, "exports": { "./package.json": "./package.json", ".": { - "types": "./core/dist/index.d.ts", "react-server": "./core/dist/react-server.mjs", "import": "./core/dist/index.mjs", "module": "./core/dist/index.esm.js", "require": "./core/dist/index.js" }, "./infinite": { - "types": "./infinite/dist/index.d.ts", "react-server": "./infinite/dist/react-server.mjs", "import": "./infinite/dist/index.mjs", "module": "./infinite/dist/index.esm.js", "require": "./infinite/dist/index.js" }, "./immutable": { - "types": "./immutable/dist/index.d.ts", "import": "./immutable/dist/index.mjs", "module": "./immutable/dist/index.esm.js", "require": "./immutable/dist/index.js" }, "./subscription": { - "types": "./subscription/dist/index.d.ts", "import": "./subscription/dist/index.mjs", "module": "./subscription/dist/index.esm.js", "require": "./subscription/dist/index.js" }, "./mutation": { - "types": "./mutation/dist/index.d.ts", "import": "./mutation/dist/index.mjs", "module": "./mutation/dist/index.esm.js", "require": "./mutation/dist/index.js" }, "./_internal": { - "types": "./_internal/dist/index.d.ts", "react-server": "./_internal/dist/react-server.mjs", "import": "./_internal/dist/index.mjs", "module": "./_internal/dist/index.esm.js", @@ -57,12 +67,12 @@ } }, "files": [ - "core/dist/**/*.{js,d.ts,mjs}", - "infinite/dist/**/*.{js,d.ts,mjs}", - "immutable/dist/**/*.{js,d.ts,mjs}", - "mutation/dist/**/*.{js,d.ts,mjs}", - "_internal/dist/**/*.{js,d.ts,mjs}", - "subscription/dist/*.{js,d.ts,mjs}", + "core/dist/**/*.{js,d.ts,mjs,d.mts}", + "infinite/dist/**/*.{js,d.ts,mjs,d.mts}", + "immutable/dist/**/*.{js,d.ts,mjs,d.mts}", + "mutation/dist/**/*.{js,d.ts,mjs,d.mts}", + "_internal/dist/**/*.{js,d.ts,mjs,d.mts}", + "subscription/dist/*.{js,d.ts,mjs,d.mts}", "core/package.json", "infinite/package.json", "immutable/package.json", @@ -82,6 +92,7 @@ "build": "pnpm build-package _internal && pnpm build-package core && pnpm build-package infinite && pnpm build-package immutable && pnpm build-package mutation && pnpm build-package subscription", "build:e2e": "pnpm next build e2e/site", "build-package": "bunchee --cwd", + "attw": "attw --pack", "types:check": "pnpm -r run types:check", "prepublishOnly": "pnpm clean && pnpm build", "publish-beta": "pnpm publish --tag beta", @@ -93,7 +104,7 @@ "test": "jest", "test:build": "jest --config jest.config.build.js", "test:e2e": "playwright test", - "run-all-checks": "pnpm types:check && pnpm lint && pnpm test && pnpm test-typing" + "run-all-checks": "pnpm types:check && pnpm lint && pnpm test-typing" }, "lint-staged": { "*.{ts,tsx}": [ @@ -102,6 +113,7 @@ ] }, "devDependencies": { + "@arethetypeswrong/cli": "^0.7.0", "@playwright/test": "^1.34.3", "@swc/core": "^1.3.62", "@swc/jest": "0.2.26", @@ -114,7 +126,7 @@ "@types/use-sync-external-store": "^0.0.3", "@typescript-eslint/eslint-plugin": "5.59.8", "@typescript-eslint/parser": "5.59.8", - "bunchee": "3.5.0", + "bunchee": "3.6.0", "eslint": "8.42.0", "eslint-config-prettier": "8.8.0", "eslint-plugin-jest-dom": "5.0.1", @@ -150,4 +162,4 @@ "client-only": "^0.0.1", "use-sync-external-store": "^1.2.0" } -} +} \ No newline at end of file diff --git a/pnpm-lock.yaml b/pnpm-lock.yaml index 2b6e62093..198a21287 100644 --- a/pnpm-lock.yaml +++ b/pnpm-lock.yaml @@ -1,5 +1,9 @@ lockfileVersion: '6.0' +settings: + autoInstallPeers: false + excludeLinksFromLockfile: false + importers: .: @@ -11,6 +15,9 @@ importers: specifier: ^1.2.0 version: 1.2.0(react@18.2.0) devDependencies: + '@arethetypeswrong/cli': + specifier: ^0.7.0 + version: 0.7.0 '@playwright/test': specifier: ^1.34.3 version: 1.34.3 @@ -48,8 +55,8 @@ importers: specifier: 5.59.8 version: 5.59.8(eslint@8.42.0)(typescript@5.1.3) bunchee: - specifier: 3.5.0 - version: 3.5.0(typescript@5.1.3) + specifier: 3.6.0 + version: 3.6.0(typescript@5.1.3) eslint: specifier: 8.42.0 version: 8.42.0 @@ -132,6 +139,37 @@ packages: '@jridgewell/trace-mapping': 0.3.17 dev: true + /@andrewbranch/untar.js@1.0.2: + resolution: {integrity: sha512-hL80MHK3b++pEp6K23+Nl5r5D1F19DRagp2ruCBIv4McyCiLKq67vUNvEQY1aGCAKNZ8GxV23n5MhOm7RwO8Pg==} + dev: true + + /@arethetypeswrong/cli@0.7.0: + resolution: {integrity: sha512-fNX9abfPkhYPUlfSI38L0TtbJWIIGuMF1TQsnw9GzAeg6FFWEj5HYoI0pRj049p++BgM9/ikRy1RS2BBDkCHXQ==} + hasBin: true + dependencies: + '@arethetypeswrong/core': 0.7.0 + chalk: 4.1.2 + cli-table3: 0.6.3 + commander: 10.0.1 + marked: 5.1.1 + marked-terminal: 5.2.0(marked@5.1.1) + transitivePeerDependencies: + - encoding + dev: true + + /@arethetypeswrong/core@0.7.0: + resolution: {integrity: sha512-qwWmIm8YNvmSOgDXEDJUEjd1yGX4bTY0838A+wCTHlOm2n/lFhjauZjAxfKu9DHn2TSGnHahD07tGDPp4I7fSg==} + dependencies: + '@andrewbranch/untar.js': 1.0.2 + fetch-ponyfill: 7.1.0 + fflate: 0.7.4 + semver: 7.5.4 + typescript: 5.1.3 + validate-npm-package-name: 5.0.0 + transitivePeerDependencies: + - encoding + dev: true + /@babel/code-frame@7.18.6: resolution: {integrity: sha512-TDCmlK5eOvH+eH7cdAFlNXeVJqWIQ7gW9tY1GJIpUtFb6CmjVyq2VM3u71bOyR8CRihcCgMUYoDNyLXao3+70Q==} engines: {node: '>=6.9.0'} @@ -471,6 +509,13 @@ packages: resolution: {integrity: sha512-0hYQ8SB4Db5zvZB4axdMHGwEaQjkZzFjQiN9LVYvIFB2nSUHW9tYpxWriPrWDASIxiaXax83REcLxuSdnGPZtw==} dev: true + /@colors/colors@1.5.0: + resolution: {integrity: sha512-ooWCrlZP11i8GImSjTHYHLkvFDP48nS4+204nGb1RiX/WXYHmJA2III9/e2DWVabCESdW7hBAEzHRqUn9OUVvQ==} + engines: {node: '>=0.1.90'} + requiresBuild: true + dev: true + optional: true + /@eslint-community/eslint-utils@4.4.0(eslint@8.42.0): resolution: {integrity: sha512-1/sA4dwrzBAyeUoQ6oxahHKmrZvsnLCg4RfxW3ZFGGmQkSNQPFNLV9CUEFQP1x9EYXHTo5p6xdhZM1Ne9p/AfA==} engines: {node: ^12.22.0 || ^14.17.0 || >=16.0.0} @@ -829,6 +874,142 @@ packages: '@jridgewell/sourcemap-codec': 1.4.14 dev: true + /@napi-rs/magic-string-android-arm-eabi@0.3.4: + resolution: {integrity: sha512-sszAYxqtzzJ4FDerDNHcqL9NhqPhj8W4DNiOanXYy50mA5oojlRtaAFPiB5ZMrWDBM32v5Q30LrmxQ4eTtu2Dg==} + engines: {node: '>= 10'} + cpu: [arm] + os: [android] + requiresBuild: true + dev: true + optional: true + + /@napi-rs/magic-string-android-arm64@0.3.4: + resolution: {integrity: sha512-jdQ6HuO0X5rkX4MauTcWR4HWdgjakTOmmzqXg8L26+jOHVVG1LZE+Su5qvV4bP8vMb2h+vPE+JsnwqSmWymu3Q==} + engines: {node: '>= 10'} + cpu: [arm64] + os: [android] + requiresBuild: true + dev: true + optional: true + + /@napi-rs/magic-string-darwin-arm64@0.3.4: + resolution: {integrity: sha512-6NmMtvURce9/oq09XBZmuIeI6lPLGtEJ2ZPO/QzL3nLZa6wygiCnO/sFACKYNg5/73ET5HMMTeuogE1JI+r2Lw==} + engines: {node: '>= 10'} + cpu: [arm64] + os: [darwin] + requiresBuild: true + dev: true + optional: true + + /@napi-rs/magic-string-darwin-x64@0.3.4: + resolution: {integrity: sha512-f9LmfMiUAKDOtl0meOuLYeVb6OERrgGzrTg1Tn3R3fTAShM2kxRbfAuPE9ljuXxIFzOv/uqRNLSl/LqCJwpREA==} + engines: {node: '>= 10'} + cpu: [x64] + os: [darwin] + requiresBuild: true + dev: true + optional: true + + /@napi-rs/magic-string-freebsd-x64@0.3.4: + resolution: {integrity: sha512-rqduQ4odiDK4QdM45xHWRTU4wtFIfpp8g8QGpz+3qqg7ivldDqbbNOrBaf6Oeu77uuEvWggnkyuChotfKgJdJQ==} + engines: {node: '>= 10'} + cpu: [x64] + os: [freebsd] + requiresBuild: true + dev: true + optional: true + + /@napi-rs/magic-string-linux-arm-gnueabihf@0.3.4: + resolution: {integrity: sha512-pVaJEdEpiPqIfq3M4+yMAATS7Z9muDcWYn8H7GFH1ygh8GwgLgKfy/n/lG2M6zp18Mwd0x7E2E/qg9GgCyUzoQ==} + engines: {node: '>= 10'} + cpu: [arm] + os: [linux] + requiresBuild: true + dev: true + optional: true + + /@napi-rs/magic-string-linux-arm64-gnu@0.3.4: + resolution: {integrity: sha512-9FwoAih/0tzEZx0BjYYIxWkSRMjonIn91RFM3q3MBs/evmThXUYXUqLNa1PPIkK1JoksswtDi48qWWLt8nGflQ==} + engines: {node: '>= 10'} + cpu: [arm64] + os: [linux] + requiresBuild: true + dev: true + optional: true + + /@napi-rs/magic-string-linux-arm64-musl@0.3.4: + resolution: {integrity: sha512-wCR7R+WPOcAKmVQc1s6h6HwfwW1vL9pM8BjUY9Ljkdb8wt1LmZEmV2Sgfc1SfbRQzbyl+pKeufP6adRRQVzYDA==} + engines: {node: '>= 10'} + cpu: [arm64] + os: [linux] + requiresBuild: true + dev: true + optional: true + + /@napi-rs/magic-string-linux-x64-gnu@0.3.4: + resolution: {integrity: sha512-sbxFDpYnt5WFbxQ1xozwOvh5A7IftqSI0WnE9O7KsQIOi0ej2dvFbfOW4tmFkvH/YP8KJELo5AhP2+kEq1DpYA==} + engines: {node: '>= 10'} + cpu: [x64] + os: [linux] + requiresBuild: true + dev: true + optional: true + + /@napi-rs/magic-string-linux-x64-musl@0.3.4: + resolution: {integrity: sha512-jN4h/7e2Ul8v3UK5IZu38NXLMdzVWhY4uEDlnwuUAhwRh26wBQ1/pLD97Uy/Z3dFNBQPcsv60XS9fOM1YDNT6w==} + engines: {node: '>= 10'} + cpu: [x64] + os: [linux] + requiresBuild: true + dev: true + optional: true + + /@napi-rs/magic-string-win32-arm64-msvc@0.3.4: + resolution: {integrity: sha512-gMUyTRHLWpzX2ntJFCbW2Gnla9Y/WUmbkZuW5SBAo/Jo8QojHn76Y4PNgnoXdzcsV9b/45RBxurYKAfFg9WTyg==} + engines: {node: '>= 10'} + cpu: [arm64] + os: [win32] + requiresBuild: true + dev: true + optional: true + + /@napi-rs/magic-string-win32-ia32-msvc@0.3.4: + resolution: {integrity: sha512-QIMauMOvEHgL00K9np/c9CT/CRtLOz3mRTQqcZ9XGzSoAMrpxH71KSpDJrKl7h7Ro6TZ+hJ0C3T+JVuTCZNv4A==} + engines: {node: '>= 10'} + cpu: [ia32] + os: [win32] + requiresBuild: true + dev: true + optional: true + + /@napi-rs/magic-string-win32-x64-msvc@0.3.4: + resolution: {integrity: sha512-V8FMSf828MzOI3P6/765MR7zHU6CUZqiyPhmAnwYoKFNxfv7oCviN/G6NcENeCdcYOvNgh5fYzaNLB96ndId5A==} + engines: {node: '>= 10'} + cpu: [x64] + os: [win32] + requiresBuild: true + dev: true + optional: true + + /@napi-rs/magic-string@0.3.4: + resolution: {integrity: sha512-DEWl/B99RQsyMT3F9bvrXuhL01/eIQp/dtNSE3G1jQ4mTGRcP4iHWxoPZ577WrbjUinrNgvRA5+08g8fkPgimQ==} + engines: {node: '>= 10'} + optionalDependencies: + '@napi-rs/magic-string-android-arm-eabi': 0.3.4 + '@napi-rs/magic-string-android-arm64': 0.3.4 + '@napi-rs/magic-string-darwin-arm64': 0.3.4 + '@napi-rs/magic-string-darwin-x64': 0.3.4 + '@napi-rs/magic-string-freebsd-x64': 0.3.4 + '@napi-rs/magic-string-linux-arm-gnueabihf': 0.3.4 + '@napi-rs/magic-string-linux-arm64-gnu': 0.3.4 + '@napi-rs/magic-string-linux-arm64-musl': 0.3.4 + '@napi-rs/magic-string-linux-x64-gnu': 0.3.4 + '@napi-rs/magic-string-linux-x64-musl': 0.3.4 + '@napi-rs/magic-string-win32-arm64-msvc': 0.3.4 + '@napi-rs/magic-string-win32-ia32-msvc': 0.3.4 + '@napi-rs/magic-string-win32-x64-msvc': 0.3.4 + dev: true + /@next/env@13.4.4: resolution: {integrity: sha512-q/y7VZj/9YpgzDe64Zi6rY1xPizx80JjlU2BTevlajtaE3w1LqweH1gGgxou2N7hdFosXHjGrI4OUvtFXXhGLg==} dev: true @@ -1067,15 +1248,6 @@ packages: '@sinonjs/commons': 2.0.0 dev: true - /@swc/core-darwin-arm64@1.3.46: - resolution: {integrity: sha512-kY4ASe7SsntDw2B1T70H9K1CFmK8POi+LyIpeCyC96EB9wbH2Sax+ploBB/wZALbYzr/dMJzOCU8QXzdmVS4Rg==} - engines: {node: '>=10'} - cpu: [arm64] - os: [darwin] - requiresBuild: true - dev: true - optional: true - /@swc/core-darwin-arm64@1.3.62: resolution: {integrity: sha512-MmGilibITz68LEje6vJlKzc2gUUSgzvB3wGLSjEORikTNeM7P8jXVxE4A8fgZqDeudJUm9HVWrxCV+pHDSwXhA==} engines: {node: '>=10'} @@ -1085,10 +1257,10 @@ packages: dev: true optional: true - /@swc/core-darwin-x64@1.3.46: - resolution: {integrity: sha512-kE3PMk8xW+2BZ3oZiTxxsUU/GzrGwM+qS4frOBz9TYHZe+W1dTtj4F9vBit4PFJ+tv4O6DPt9neGobzdq0UmRw==} + /@swc/core-darwin-arm64@1.3.70: + resolution: {integrity: sha512-31+mcl0dgdRHvZRjhLOK9V6B+qJ7nxDZYINr9pBlqGWxknz37Vld5KK19Kpr79r0dXUZvaaelLjCnJk9dA2PcQ==} engines: {node: '>=10'} - cpu: [x64] + cpu: [arm64] os: [darwin] requiresBuild: true dev: true @@ -1103,11 +1275,11 @@ packages: dev: true optional: true - /@swc/core-linux-arm-gnueabihf@1.3.46: - resolution: {integrity: sha512-7TbiUr9MYxT+mC7sVrayag/isFoaZUG/ogkEK8B/ouA1pnIYqWh3N5ifqCzfcSRiOURt+vVqPyoO1puSiNzVuQ==} + /@swc/core-darwin-x64@1.3.70: + resolution: {integrity: sha512-GMFJ65E18zQC80t0os+TZvI+8lbRuitncWVge/RXmXbVLPRcdykP4EJ87cqzcG5Ah0z18/E0T+ixD6jHRisrYQ==} engines: {node: '>=10'} - cpu: [arm] - os: [linux] + cpu: [x64] + os: [darwin] requiresBuild: true dev: true optional: true @@ -1121,10 +1293,10 @@ packages: dev: true optional: true - /@swc/core-linux-arm64-gnu@1.3.46: - resolution: {integrity: sha512-Ycw4LU/wsUK9R+Y/2qFOPQseZDfM5D5gbWGrrYj5RoTm57FbnUsSsO26QeZxUNvams1oAQDkZDuerCc9qBRzIQ==} + /@swc/core-linux-arm-gnueabihf@1.3.70: + resolution: {integrity: sha512-wjhCwS8LCiAq2VedF1b4Bryyw68xZnfMED4pLRazAl8BaUlDFANfRBORNunxlfHQj4V3x39IaiLgCZRHMdzXBg==} engines: {node: '>=10'} - cpu: [arm64] + cpu: [arm] os: [linux] requiresBuild: true dev: true @@ -1139,8 +1311,8 @@ packages: dev: true optional: true - /@swc/core-linux-arm64-musl@1.3.46: - resolution: {integrity: sha512-cBclyr6IW1PBr8l9D4FkebgbqlkiIYnSJCbY84J/6PfTzQlD6w9a1TAoYxdGZpJ7SGHdmB0oDiZS1rhxCSCV/Q==} + /@swc/core-linux-arm64-gnu@1.3.70: + resolution: {integrity: sha512-9D/Rx67cAOnMiexvCqARxvhj7coRajTp5HlJHuf+rfwMqI2hLhpO9/pBMQxBUAWxODO/ksQ/OF+GJRjmtWw/2A==} engines: {node: '>=10'} cpu: [arm64] os: [linux] @@ -1157,10 +1329,10 @@ packages: dev: true optional: true - /@swc/core-linux-x64-gnu@1.3.46: - resolution: {integrity: sha512-amqMhTA2CXB6t11hVAZSSPKq4DZ9/sWbW3wYYQHxzqrMJML0726OJs4pt0XnlU7FzdP/9M9j2B/gWCRaCMxXVA==} + /@swc/core-linux-arm64-musl@1.3.70: + resolution: {integrity: sha512-gkjxBio7XD+1GlQVVyPP/qeFkLu83VhRHXaUrkNYpr5UZG9zZurBERT9nkS6Y+ouYh+Q9xmw57aIyd2KvD2zqQ==} engines: {node: '>=10'} - cpu: [x64] + cpu: [arm64] os: [linux] requiresBuild: true dev: true @@ -1175,8 +1347,8 @@ packages: dev: true optional: true - /@swc/core-linux-x64-musl@1.3.46: - resolution: {integrity: sha512-WOQZTIkJ9khIj5Z2unf6OTrWV9k8br+HZ93RvnamEmJBlLPUuT9IjB+agNhjaDgOpz9/ZldSGqV7vzl5FGQl1Q==} + /@swc/core-linux-x64-gnu@1.3.70: + resolution: {integrity: sha512-/nCly+V4xfMVwfEUoLLAukxUSot/RcSzsf6GdsGTjFcrp5sZIntAjokYRytm3VT1c2TK321AfBorsi9R5w8Y7Q==} engines: {node: '>=10'} cpu: [x64] os: [linux] @@ -1193,11 +1365,11 @@ packages: dev: true optional: true - /@swc/core-win32-arm64-msvc@1.3.46: - resolution: {integrity: sha512-4JSREbqaTRQ6QO0EeoiB6G5vuFT8zI8aTOLu5At7Cvlw+X7bOGNO+wJ3Tqw7O+68OL+0bPHzHGTXKL9kUccY1A==} + /@swc/core-linux-x64-musl@1.3.70: + resolution: {integrity: sha512-HoOsPJbt361KGKaivAK0qIiYARkhzlxeAfvF5NlnKxkIMOZpQ46Lwj3tR0VWohKbrhS+cYKFlVuDi5XnDkx0XA==} engines: {node: '>=10'} - cpu: [arm64] - os: [win32] + cpu: [x64] + os: [linux] requiresBuild: true dev: true optional: true @@ -1211,10 +1383,10 @@ packages: dev: true optional: true - /@swc/core-win32-ia32-msvc@1.3.46: - resolution: {integrity: sha512-kC8dIDzcArm1e85yHJsEZFxcNq5NztLkrqkP1nVOQ+9QXD9DKhjbZtWy2gnpclinii6KEGng8SieWiJiOA0CBQ==} + /@swc/core-win32-arm64-msvc@1.3.70: + resolution: {integrity: sha512-hm4IBK/IaRil+aj1cWU6f0GyAdHpw/Jr5nyFYLM2c/tt7w2t5hgb8NjzM2iM84lOClrig1fG6edj2vCF1dFzNQ==} engines: {node: '>=10'} - cpu: [ia32] + cpu: [arm64] os: [win32] requiresBuild: true dev: true @@ -1229,10 +1401,10 @@ packages: dev: true optional: true - /@swc/core-win32-x64-msvc@1.3.46: - resolution: {integrity: sha512-rrSAfq+DvpJioBxUsnuH+sKl0eXid1DwkwNzkVGHEreN9GoP7GospWtFq7VDcO6DrS/s3HtR4/TzoIYFEBCRIg==} + /@swc/core-win32-ia32-msvc@1.3.70: + resolution: {integrity: sha512-5cgKUKIT/9Fp5fCA+zIjYCQ4dSvjFYOeWGZR3QiTXGkC4bGa1Ji9SEPyeIAX0iruUnKjYaZB9RvHK2tNn7RLrQ==} engines: {node: '>=10'} - cpu: [x64] + cpu: [ia32] os: [win32] requiresBuild: true dev: true @@ -1247,26 +1419,14 @@ packages: dev: true optional: true - /@swc/core@1.3.46(@swc/helpers@0.5.0): - resolution: {integrity: sha512-WxzgJMWUBVJ95HsvEqlWzM3Qxp2FQrPa4QdAkQQuuvCMnfdctGUbhX/c3LiSRlWrl2LIkYAi4bLansTOol4QcQ==} + /@swc/core-win32-x64-msvc@1.3.70: + resolution: {integrity: sha512-LE8lW46+TQBzVkn2mHBlk8DIElPIZ2dO5P8AbJiARNBAnlqQWu67l9gWM89UiZ2l33J2cI37pHzON3tKnT8f9g==} engines: {node: '>=10'} + cpu: [x64] + os: [win32] requiresBuild: true - peerDependencies: - '@swc/helpers': ^0.5.0 - dependencies: - '@swc/helpers': 0.5.0 - optionalDependencies: - '@swc/core-darwin-arm64': 1.3.46 - '@swc/core-darwin-x64': 1.3.46 - '@swc/core-linux-arm-gnueabihf': 1.3.46 - '@swc/core-linux-arm64-gnu': 1.3.46 - '@swc/core-linux-arm64-musl': 1.3.46 - '@swc/core-linux-x64-gnu': 1.3.46 - '@swc/core-linux-x64-musl': 1.3.46 - '@swc/core-win32-arm64-msvc': 1.3.46 - '@swc/core-win32-ia32-msvc': 1.3.46 - '@swc/core-win32-x64-msvc': 1.3.46 dev: true + optional: true /@swc/core@1.3.62: resolution: {integrity: sha512-J58hWY+/G8vOr4J6ZH9hLg0lMSijZtqIIf4HofZezGog/pVX6sJyBJ40dZ1ploFkDIlWTWvJyqtpesBKS73gkQ==} @@ -1290,10 +1450,28 @@ packages: '@swc/core-win32-x64-msvc': 1.3.62 dev: true - /@swc/helpers@0.5.0: - resolution: {integrity: sha512-SjY/p4MmECVVEWspzSRpQEM3sjR17sP8PbGxELWrT+YZMBfiUyt1MRUNjMV23zohwlG2HYtCQOsCwsTHguXkyg==} + /@swc/core@1.3.70(@swc/helpers@0.5.1): + resolution: {integrity: sha512-LWVWlEDLlOD25PvA2NEz41UzdwXnlDyBiZbe69s3zM0DfCPwZXLUm79uSqH9ItsOjTrXSL5/1+XUL6C/BZwChA==} + engines: {node: '>=10'} + requiresBuild: true + peerDependencies: + '@swc/helpers': ^0.5.0 + peerDependenciesMeta: + '@swc/helpers': + optional: true dependencies: - tslib: 2.5.0 + '@swc/helpers': 0.5.1 + optionalDependencies: + '@swc/core-darwin-arm64': 1.3.70 + '@swc/core-darwin-x64': 1.3.70 + '@swc/core-linux-arm-gnueabihf': 1.3.70 + '@swc/core-linux-arm64-gnu': 1.3.70 + '@swc/core-linux-arm64-musl': 1.3.70 + '@swc/core-linux-x64-gnu': 1.3.70 + '@swc/core-linux-x64-musl': 1.3.70 + '@swc/core-win32-arm64-msvc': 1.3.70 + '@swc/core-win32-ia32-msvc': 1.3.70 + '@swc/core-win32-x64-msvc': 1.3.70 dev: true /@swc/helpers@0.5.1: @@ -1770,6 +1948,13 @@ packages: type-fest: 0.21.3 dev: true + /ansi-escapes@6.2.0: + resolution: {integrity: sha512-kzRaCqXnpzWs+3z5ABPQiVke+iq0KXkHo8xiWV4RPTi5Yli0l97BEQuhXV1s7+aSU/fu1kUuxgS4MsQ0fRuygw==} + engines: {node: '>=14.16'} + dependencies: + type-fest: 3.13.1 + dev: true + /ansi-regex@5.0.1: resolution: {integrity: sha512-quJQXlTSUGL2LH9SUXo8VwsY4soanhgo6LNSm84E1LBcE8s3O0wpdiRzyR9z/ZZJMlMWv37qOOb9pdJlMUEKFQ==} engines: {node: '>=8'} @@ -1804,6 +1989,10 @@ packages: engines: {node: '>=12'} dev: true + /ansicolors@0.3.2: + resolution: {integrity: sha512-QXu7BPrP29VllRxH8GwB7x5iX5qWKAAMLqKQGWTeLWVlNHNOpVMJ91dsxQAIWXpjuW5wqvxu3Jd/nRjrJ+0pqg==} + dev: true + /anymatch@3.1.2: resolution: {integrity: sha512-P43ePfOAIupkguHUycrc4qJ9kz8ZiuOUijaETwX7THt0Y/GNK7v0aa8rY816xWjZ7rJdA5XdMcpVFTKMq+RvWg==} engines: {node: '>= 8'} @@ -1998,8 +2187,14 @@ packages: engines: {node: '>=6'} dev: true - /bunchee@3.5.0(typescript@5.1.3): - resolution: {integrity: sha512-lJBj1U2nZQEQpNt1h0f3rGx2sn2qA9BHzGPpLRuJlUAKCOz3n8WU6P/mPPmGKn1NTuS9+OoTuEX4JW8lvZFBwg==} + /builtins@5.0.1: + resolution: {integrity: sha512-qwVpFEHNfhYJIzNRBvd2C1kyo6jz3ZSMPyyuR47OPdiKWlbYnZNyDWuyR175qDnAJLiCo5fBBqPb3RiXgWlkOQ==} + dependencies: + semver: 7.5.4 + dev: true + + /bunchee@3.6.0(typescript@5.1.3): + resolution: {integrity: sha512-aK8HjzNJ8UMopQArKgwmcfwuGQ5UAMEt786H1CQGXRaXcwlVDIwuibUc8OwFpchTkJK3Nrr3jOw/tb0ZJRBoMA==} engines: {node: '>= 16'} hasBin: true peerDependencies: @@ -2015,15 +2210,15 @@ packages: '@rollup/plugin-node-resolve': 15.0.2(rollup@3.20.2) '@rollup/plugin-replace': 5.0.2(rollup@3.20.2) '@rollup/plugin-wasm': 6.1.3(rollup@3.20.2) - '@swc/core': 1.3.46(@swc/helpers@0.5.0) - '@swc/helpers': 0.5.0 + '@swc/core': 1.3.70(@swc/helpers@0.5.1) + '@swc/helpers': 0.5.1 arg: 5.0.2 - magic-string: 0.30.0 pretty-bytes: 5.6.0 publint: 0.1.11 rollup: 3.20.2 rollup-plugin-dts: 5.3.0(rollup@3.20.2)(typescript@5.1.3) - rollup-plugin-swc3: 0.8.1(@swc/core@1.3.46)(rollup@3.20.2) + rollup-plugin-swc3: 0.8.1(@swc/core@1.3.70)(rollup@3.20.2) + rollup-swc-preserve-directives: 0.3.1(@swc/core@1.3.70)(rollup@3.20.2) tslib: 2.5.0 typescript: 5.1.3 dev: true @@ -2061,6 +2256,14 @@ packages: resolution: {integrity: sha512-1MgUzEkoMO6gKfXflStpYgZDlFM7M/ck/bgfVCACO5vnAf0fXoNVHdWtqGU+MYca+4bL9Z5bpOVmR33cWW9G2A==} dev: true + /cardinal@2.1.1: + resolution: {integrity: sha512-JSr5eOgoEymtYHBjNWyjrMqet9Am2miJhlfKNdqLp6zoeAh0KN5dRAcxlecj5mAJrmQomgiOBj35xHLrFjqBpw==} + hasBin: true + dependencies: + ansicolors: 0.3.2 + redeyed: 2.1.1 + dev: true + /chalk@2.4.2: resolution: {integrity: sha512-Mti+f9lpJNcwF4tWV8/OrTTtF1gZi+f8FqlyAdouralcFWFQWF2+NgCHShjkCb+IFBLq9buZwE1xckQU4peSuQ==} engines: {node: '>=4'} @@ -2116,6 +2319,15 @@ packages: restore-cursor: 3.1.0 dev: true + /cli-table3@0.6.3: + resolution: {integrity: sha512-w5Jac5SykAeZJKntOxJCrm63Eg5/4dhMWIcuTbo9rpE+brgaSZo0RuNJZeOyMgsUdhDeojvgyQLmjI+K50ZGyg==} + engines: {node: 10.* || >= 12.*} + dependencies: + string-width: 4.2.3 + optionalDependencies: + '@colors/colors': 1.5.0 + dev: true + /cli-truncate@2.1.0: resolution: {integrity: sha512-n8fOixwDD6b/ObinzTrp1ZKFzbgvKZvuz/TvejnLn1aQfC6r52XEx85FmuC+3HI+JM7coBRXUvNqEU2PHVrHpg==} engines: {node: '>=8'} @@ -2708,6 +2920,18 @@ packages: bser: 2.1.1 dev: true + /fetch-ponyfill@7.1.0: + resolution: {integrity: sha512-FhbbL55dj/qdVO3YNK7ZEkshvj3eQ7EuIGV2I6ic/2YiocvyWv+7jg2s4AyS0wdRU75s3tA8ZxI/xPigb0v5Aw==} + dependencies: + node-fetch: 2.6.12 + transitivePeerDependencies: + - encoding + dev: true + + /fflate@0.7.4: + resolution: {integrity: sha512-5u2V/CDW15QM1XbbgS+0DfPxVB+jUKhWEKuuFuHncbk3tEEqzmoXL+2KyOFuKGqOnmdIy0/davWF1CkuwtibCw==} + dev: true + /file-entry-cache@6.0.1: resolution: {integrity: sha512-7Gps/XWymbLk2QLYK4NzpMOrYjMhdIxXuIvy2QBsLE6ljuodKvdkWs/cpyJJ3CVIVpH0Oi1Hvg1ovbMzLdFBBg==} engines: {node: ^10.12.0 || >=12.0.0} @@ -3975,6 +4199,27 @@ packages: tmpl: 1.0.5 dev: true + /marked-terminal@5.2.0(marked@5.1.1): + resolution: {integrity: sha512-Piv6yNwAQXGFjZSaiNljyNFw7jKDdGrw70FSbtxEyldLsyeuV5ZHm/1wW++kWbrOF1VPnUgYOhB2oLL0ZpnekA==} + engines: {node: '>=14.13.1 || >=16.0.0'} + peerDependencies: + marked: ^1.0.0 || ^2.0.0 || ^3.0.0 || ^4.0.0 || ^5.0.0 + dependencies: + ansi-escapes: 6.2.0 + cardinal: 2.1.1 + chalk: 5.2.0 + cli-table3: 0.6.3 + marked: 5.1.1 + node-emoji: 1.11.0 + supports-hyperlinks: 2.3.0 + dev: true + + /marked@5.1.1: + resolution: {integrity: sha512-bTmmGdEINWmOMDjnPWDxGPQ4qkDLeYorpYbEtFOXzOruTwUE671q4Guiuchn4N8h/v6NGd7916kXsm3Iz4iUSg==} + engines: {node: '>= 18'} + hasBin: true + dev: true + /merge-stream@2.0.0: resolution: {integrity: sha512-abv/qOcuPfk3URPfDzmZU1LKmuw8kT+0nIHvKrKgFrwifol/doWcdA4ZqsWQ8ENrFKkd67Mfpo/LovbIUsbt3w==} dev: true @@ -4109,6 +4354,24 @@ packages: - babel-plugin-macros dev: true + /node-emoji@1.11.0: + resolution: {integrity: sha512-wo2DpQkQp7Sjm2A0cq+sN7EHKO6Sl0ctXeBdFZrL9T9+UywORbufTcTZxom8YqpLQt/FqNMUkOpkZrJVYSKD3A==} + dependencies: + lodash: 4.17.21 + dev: true + + /node-fetch@2.6.12: + resolution: {integrity: sha512-C/fGU2E8ToujUivIO0H+tpQ6HWo4eEmchoPIoXtxCrVghxdKq+QOHqEZW7tuP3KlV3bC8FRMO5nMCC7Zm1VP6g==} + engines: {node: 4.x || >=6.0.0} + peerDependencies: + encoding: ^0.1.0 + peerDependenciesMeta: + encoding: + optional: true + dependencies: + whatwg-url: 5.0.0 + dev: true + /node-int64@0.4.0: resolution: {integrity: sha512-O5lz91xSOeoXP6DulyHfllpq+Eg00MWitZIbtPfoSEvqIHdl5gfcY6hYzDWnj0qD5tz52PI08u9qUvSVeUBeHw==} dev: true @@ -4538,6 +4801,12 @@ packages: strip-indent: 3.0.0 dev: true + /redeyed@2.1.1: + resolution: {integrity: sha512-FNpGGo1DycYAdnrKFxCMmKYgo/mILAqtRYbkdQD8Ep/Hk2PQ5+aEAEx+IU713RTDmuBaH0c8P5ZozurNu5ObRQ==} + dependencies: + esprima: 4.0.1 + dev: true + /regenerator-runtime@0.13.9: resolution: {integrity: sha512-p3VT+cOEgxFsRRA9X4lkI1E+k2/CtnKtU4gcxyaCUreilL/vqI6CdZ3wxVUx3UOUg+gnUOQQcRI7BmSI656MYA==} dev: true @@ -4651,7 +4920,7 @@ packages: '@babel/code-frame': 7.21.4 dev: true - /rollup-plugin-swc3@0.8.1(@swc/core@1.3.46)(rollup@3.20.2): + /rollup-plugin-swc3@0.8.1(@swc/core@1.3.70)(rollup@3.20.2): resolution: {integrity: sha512-xoHRmrGamXrz4rNfmXiTNf/6pAYY2daFOJavVsrG/HvBgsoa8lx9rtas9XiqOl5DqD04tGn8MiUwarITOPyh8A==} engines: {node: '>=12'} peerDependencies: @@ -4660,11 +4929,22 @@ packages: dependencies: '@fastify/deepmerge': 1.3.0 '@rollup/pluginutils': 4.2.1 - '@swc/core': 1.3.46(@swc/helpers@0.5.0) + '@swc/core': 1.3.70(@swc/helpers@0.5.1) get-tsconfig: 4.2.0 rollup: 3.20.2 dev: true + /rollup-swc-preserve-directives@0.3.1(@swc/core@1.3.70)(rollup@3.20.2): + resolution: {integrity: sha512-bQvf3ROvWSQr8nj+6sz5Dix2BOBYrGfy9GXz6BFsP701GwmYEc2MKi6IFA5/7+4GLTSYWEfh1jE67VJmZ5842w==} + peerDependencies: + '@swc/core': '>=1.2.165' + rollup: ^2.0.0 || ^3.0.0 + dependencies: + '@napi-rs/magic-string': 0.3.4 + '@swc/core': 1.3.70(@swc/helpers@0.5.1) + rollup: 3.20.2 + dev: true + /rollup@3.20.2: resolution: {integrity: sha512-3zwkBQl7Ai7MFYQE0y1MeQ15+9jsi7XxfrqwTb/9EK8D9C9+//EBR4M+CuA1KODRaNbFez/lWxA5vhEGZp4MUg==} engines: {node: '>=14.18.0', npm: '>=8.0.0'} @@ -4734,6 +5014,14 @@ packages: lru-cache: 6.0.0 dev: true + /semver@7.5.4: + resolution: {integrity: sha512-1bCSESV6Pv+i21Hvpxp3Dx+pSD8lIPt8uVjRrxAUt/nbswYc+tK6Y2btiULjd4+fnq15PX+nqQDC7Oft7WkwcA==} + engines: {node: '>=10'} + hasBin: true + dependencies: + lru-cache: 6.0.0 + dev: true + /shebang-command@2.0.0: resolution: {integrity: sha512-kHxr2zZpYtdmrN1qDjrrX/Z1rR1kG8Dx+gkpK1G4eXmvXswmcE1hTWBWYUzlraYw1/yZp6YuDY77YtvbN0dmDA==} engines: {node: '>=8'} @@ -4970,6 +5258,14 @@ packages: has-flag: 4.0.0 dev: true + /supports-hyperlinks@2.3.0: + resolution: {integrity: sha512-RpsAZlpWcDwOPQA22aCH4J0t7L8JmAvsCxfOSEwm7cQs3LshN36QaTkwd70DnBOXDWGssw2eUoc8CaRWT0XunA==} + engines: {node: '>=8'} + dependencies: + has-flag: 4.0.0 + supports-color: 7.2.0 + dev: true + /supports-preserve-symlinks-flag@1.0.0: resolution: {integrity: sha512-ot0WnXS9fgdkgIcePe6RHNk1WA8+muPa6cSjeR3V8K27q9BB1rTE3R1p7Hv0z1ZyAc8s6Vvv8DIyWf681MAt0w==} engines: {node: '>= 0.4'} @@ -5022,6 +5318,10 @@ packages: url-parse: 1.5.10 dev: true + /tr46@0.0.3: + resolution: {integrity: sha512-N3WMsuqV66lT30CrXNbEjx4GEwlow3v6rr4mCcv6prnfwhS01rkgyFdjPNBYd9br7LpXV1+Emh01fHnq2Gdgrw==} + dev: true + /tr46@3.0.0: resolution: {integrity: sha512-l7FvfAHlcmulp8kr+flpQZmVwtu7nfRV7NZujtN0OqES8EL4O4e0qqzL0DC5gAvx/ZC/9lk6rhcUwYvkBnBnYA==} engines: {node: '>=12'} @@ -5076,6 +5376,11 @@ packages: engines: {node: '>=10'} dev: true + /type-fest@3.13.1: + resolution: {integrity: sha512-tLq3bSNx+xSpwvAJnzrK0Ep5CLNWjvFTOp71URMaAEWBfRb9nnJiBoUe0tF8bI4ZFO3omgBR6NvnbzVUT3Ly4g==} + engines: {node: '>=14.16'} + dev: true + /typescript@5.1.3: resolution: {integrity: sha512-XH627E9vkeqhlZFQuL+UsyAXEnibT0kWR2FWONlr4sTjvxyJYnyefgrkyECLzM5NenmKzRAy2rR/OlYLA1HkZw==} engines: {node: '>=14.17'} @@ -5137,6 +5442,13 @@ packages: convert-source-map: 1.8.0 dev: true + /validate-npm-package-name@5.0.0: + resolution: {integrity: sha512-YuKoXDAhBYxY7SfOKxHBDoSyENFeW5VvIIQp2TGQuit8gpK6MnWaQelBKxso72DoxTZfZdcP3W90LqpSkgPzLQ==} + engines: {node: ^14.17.0 || ^16.13.0 || >=18.0.0} + dependencies: + builtins: 5.0.1 + dev: true + /w3c-xmlserializer@4.0.0: resolution: {integrity: sha512-d+BFHzbiCx6zGfz0HyQ6Rg69w9k19nviJspaj4yNscGjrHu94sVP+aRm75yEbCh+r2/yR+7q6hux9LVtbuTGBw==} engines: {node: '>=14'} @@ -5150,6 +5462,10 @@ packages: makeerror: 1.0.12 dev: true + /webidl-conversions@3.0.1: + resolution: {integrity: sha512-2JAn3z8AR6rjK8Sm8orRC0h/bcl/DqL7tRPdGZ4I1CjdF+EaMLmYxBHyXuKL849eucPFhvBoxMsflfOb8kxaeQ==} + dev: true + /webidl-conversions@7.0.0: resolution: {integrity: sha512-VwddBukDzu71offAQR975unBIGqfKZpM+8ZX6ySk8nYhVoo5CYaZyzt3YBvYtRtO+aoGlqxPg/B87NGVZ/fu6g==} engines: {node: '>=12'} @@ -5175,6 +5491,13 @@ packages: webidl-conversions: 7.0.0 dev: true + /whatwg-url@5.0.0: + resolution: {integrity: sha512-saE57nupxk6v3HY35+jzBwYa0rKSy0XR8JSxZPwgLr7ys0IBzhGviA1/TUGJLmSVqs8pb9AnvICXEuOHLprYTw==} + dependencies: + tr46: 0.0.3 + webidl-conversions: 3.0.1 + dev: true + /which-boxed-primitive@1.0.2: resolution: {integrity: sha512-bwZdv0AKLpplFY2KZRX6TvyuN7ojjr7lwkg6ml0roIy9YeuSr7JS372qlNW18UQYzgYK9ziGcerWqZOmEn9VNg==} dependencies: diff --git a/subscription/package.json b/subscription/package.json index 1f30b94f3..67883a9e9 100644 --- a/subscription/package.json +++ b/subscription/package.json @@ -3,7 +3,6 @@ "module": "./dist/index.esm.js", "types": "./dist/index.d.ts", "exports": { - "types": "./dist/index.d.ts", "import": "./dist/index.mjs", "module": "./dist/index.esm.js", "require": "./dist/index.js"