Files
js/packages/thirdweb/package.json
T
jnsdls 24ff6f2ab6 knip it in the... (#4751)
1. make `knip` a part of `packages/thirdweb`
2. clean up all the things
3. ???
4. profit

<!-- start pr-codex -->

---

## PR-Codex overview
This PR focuses on removing unused files, updating types, and deprecating constants.

### Detailed summary
- Removed unused files related to benchmarks, wallets, and UI components
- Updated type definitions in various files
- Deprecated and replaced constant `ADDRESS_ZERO` with `ZERO_ADDRESS`

> The following files were skipped due to too many changes: `packages/thirdweb/src/react/web/ui/ConnectWallet/Details.tsx`, `packages/thirdweb/src/pay/utils/definitions.ts`, `packages/thirdweb/src/utils/hashing/sha256.ts`, `packages/thirdweb/src/wallets/eip5792/show-calls-status.ts`, `packages/thirdweb/src/extensions/modules/ClaimableERC20/mint.ts`, `packages/thirdweb/src/react/web/wallets/shared/ConnectWalletSocialOptions.tsx`, `apps/portal/package.json`, `packages/thirdweb/src/extensions/modules/ClaimableERC721/mint.ts`, `packages/thirdweb/src/utils/hashing/hashMessage.ts`, `packages/thirdweb/src/react/native/ui/components/text.tsx`, `packages/thirdweb/src/utils/promise/resolve-promised-value.ts`, `packages/thirdweb/src/auth/core/verify-jwt.ts`, `packages/thirdweb/src/utils/hashing/keccak256.ts`, `packages/thirdweb/src/utils/uint8-array.ts`, `packages/thirdweb/src/react/core/design-system/CustomThemeProvider.tsx`, `packages/thirdweb/src/react/native/ui/connect/SendScreen.tsx`, `packages/thirdweb/src/react/web/ui/MediaRenderer/MediaRenderer.tsx`, `packages/thirdweb/src/gas/estimate-l1-fee.ts`, `packages/thirdweb/src/react/web/ui/ConnectWallet/WalletSelector.tsx`, `packages/thirdweb/src/extensions/modules/MintableERC721/mintWithSignature.ts`, `packages/thirdweb/src/react/native/ui/connect/ExternalWalletsList.tsx`, `packages/thirdweb/src/exports/extensions/erc1155.ts`, `packages/thirdweb/src/extensions/modules/ClaimableERC1155/mint.ts`, `packages/thirdweb/src/extensions/modules/MintableERC1155/mintWithSignature.ts`, `packages/thirdweb/src/utils/encoding/helpers/trim.ts`, `packages/thirdweb/src/wallets/utils/getTokenBalance.ts`, `apps/dashboard/knip.json`, `packages/thirdweb/src/react/native/ui/connect/TokenListScreen.tsx`, `packages/thirdweb/src/extensions/vote/write/executeProposal.ts`, `packages/thirdweb/src/react/native/ui/components/spinner.tsx`, `packages/thirdweb/src/react/web/ui/MediaRenderer/ModelViewer.tsx`, `packages/thirdweb/src/transaction/extract-error.ts`, `packages/thirdweb/src/react/native/ui/components/button.tsx`, `packages/thirdweb/src/extensions/erc1155/write/updateTokenURI.ts`, `packages/thirdweb/src/wallets/interfaces/wallet.ts`, `packages/thirdweb/src/react/web/ui/ConnectWallet/screens/Buy/swap/useSwapSupportedChains.ts`, `packages/thirdweb/src/utils/storage/walletStorage.ts`, `packages/thirdweb/src/wallets/in-app/native/native-connector.ts`, `packages/thirdweb/src/extensions/erc20/write/sigMint.ts`, `packages/thirdweb/src/extensions/erc721/write/updateTokenURI.ts`, `packages/thirdweb/src/react/web/wallets/ecosystem/EcosystemWalletFormUI.tsx`, `packages/thirdweb/src/wallets/eip5792/wait-for-bundle.ts`, `packages/thirdweb/src/utils/jwt/jwt-header.ts`, `packages/thirdweb/src/extensions/modules/MintableERC20/mintWithSignature.ts`, `packages/thirdweb/src/exports/modules.ts`, `packages/thirdweb/src/react/web/wallets/in-app/InAppWalletFormUI.tsx`, `packages/thirdweb/src/transaction/actions/wait-for-tx-receipt.ts`, `packages/thirdweb/src/auth/core/generate-jwt.ts`, `packages/thirdweb/src/react/core/hooks/transaction/useSendTransaction.ts`, `packages/thirdweb/src/exports/extensions/erc1271.ts`, `packages/thirdweb/src/react/web/ui/ConnectWallet/screens/Buy/main/useBuyTxStates.ts`, `packages/thirdweb/src/contract/deployment/publisher.ts`, `packages/thirdweb/src/extensions/erc721/drops/write/updateMetadata.ts`, `packages/thirdweb/src/extensions/erc1155/drops/write/updateMetadata.ts`, `packages/thirdweb/src/extensions/prebuilts/deploy-marketplace.ts`, `packages/thirdweb/src/wallets/in-app/native/auth/index.ts`, `packages/thirdweb/src/wallets/in-app/native/helpers/auth/middleware.ts`, `packages/thirdweb/src/utils/platform.ts`, `.github/CODEOWNERS`, `packages/thirdweb/src/wallets/in-app/web/lib/auth/index.ts`, `packages/thirdweb/src/react/core/utils/structuralSharing.ts`, `packages/thirdweb/src/react/core/hooks/transaction/useSendAndConfirmTransaction.ts`, `packages/thirdweb/src/extensions/prebuilts/get-required-transactions.ts`, `packages/thirdweb/src/react/web/ui/ConnectWallet/screens/Buy/pay-transactions/FiatDetailsScreen.tsx`, `packages/thirdweb/src/extensions/ens/resolve-l2-name.ts`, `packages/thirdweb/src/utils/any-evm/deploy-metadata.ts`, `packages/thirdweb/src/cli/commands/generate/utils.ts`, `packages/thirdweb/src/extensions/farcaster/eip712Signatures/keyRequestSignature.ts`, `packages/thirdweb/src/extensions/airdrop/write/airdropERC20WithSignature.ts`, `packages/thirdweb/src/extensions/airdrop/write/airdropERC721WithSignature.ts`, `packages/thirdweb/src/transaction/actions/zksync/send-eip712-transaction.ts`, `packages/thirdweb/src/wallets/in-app/web/utils/iFrameCommunication/InAppWalletIframeCommunicator.ts`, `packages/thirdweb/src/utils/any-evm/zksync/constants.ts`, `packages/thirdweb/src/extensions/marketplace/direct-listings/utils.ts`, `packages/thirdweb/src/transaction/actions/gasless/send-gasless-transaction.ts`, `packages/thirdweb/src/extensions/prebuilts/deploy-vote.ts`, `packages/thirdweb/src/react/web/ui/components/Drawer.tsx`, `packages/thirdweb/src/extensions/airdrop/write/airdropERC1155WithSignature.ts`, `packages/thirdweb/src/react/core/hooks/others/useWalletBalance.ts`, `packages/thirdweb/src/extensions/permissions/utils.ts`, `packages/thirdweb/src/wallets/in-app/native/helpers/auth/logout.ts`, `packages/thirdweb/src/wallets/smart/lib/utils.ts`, `packages/thirdweb/src/react/web/ui/components/buttons.tsx`, `packages/thirdweb/src/react/web/ui/prebuilt/thirdweb/ClaimButton/index.tsx`, `packages/thirdweb/src/wallets/wallet-connect/receiver/index.ts`, `packages/thirdweb/src/transaction/actions/gasless/providers/engine.ts`, `packages/thirdweb/src/transaction/actions/gasless/providers/openzeppelin.ts`, `packages/thirdweb/src/wallets/in-app/web/types.ts`, `packages/thirdweb/src/extensions/airdrop/write/claimERC20.ts`, `packages/thirdweb/test/globalSetup.ts`, `packages/thirdweb/src/extensions/erc721/read/getAllOwners.ts`, `packages/thirdweb/src/wallets/smart/lib/userop.ts`, `packages/thirdweb/src/wallets/in-app/native/helpers/wallet/retrieval.ts`, `packages/thirdweb/src/wallets/in-app/web/lib/iframe-wallet.ts`, `packages/thirdweb/src/react/web/ui/TransactionButton/TransactionModal.tsx`, `packages/thirdweb/src/react/native/ui/connect/ConnectedModal.tsx`, `packages/thirdweb/src/extensions/erc4337/account/common.ts`, `packages/thirdweb/test/vitest.config.ts`, `packages/thirdweb/src/exports/extensions/farcaster.ts`, `packages/thirdweb/src/exports/chains.ts`, `packages/thirdweb/src/extensions/erc4337/account/permissions.test.ts`, `packages/thirdweb/src/wallets/in-app/core/constants/settings.ts`, `packages/thirdweb/scripts/typedoc.mjs`, `packages/thirdweb/src/extensions/airdrop/write/merkleInfoERC20.ts`, `packages/thirdweb/src/utils/extensions/drops/hash-entry.ts`, `packages/thirdweb/src/extensions/farcaster/eip712Signatures/registerSignature.ts`, `packages/thirdweb/src/react/native/ui/icons/svgs.ts`, `packages/thirdweb/src/transaction/actions/gasless/providers/biconomy.ts`, `packages/thirdweb/src/extensions/farcaster/eip712Signatures/addSignature.ts`, `packages/thirdweb/src/react/web/ui/AutoConnect/AutoConnect.tsx`, `packages/thirdweb/src/react/native/ui/AutoConnect/AutoConnect.tsx`, `packages/service-utils/package.json`, `packages/thirdweb/src/stories/utils.tsx`, `packages/thirdweb/src/react/core/utils/defaultTokens.ts`, `package.json`, `packages/thirdweb/knip.json`, `packages/thirdweb/src/pay/buyWithCrypto/getStatus.ts`, `packages/thirdweb/src/exports/extensions/marketplace.ts`, `packages/thirdweb/src/utils/semver.ts`, `packages/thirdweb/src/extensions/uniswap/read/getUniswapV3Pools.ts`, `apps/dashboard/package.json`, `packages/thirdweb/src/utils/royalty-engine.ts`, `packages/react-native-adapter/package.json`, `packages/thirdweb/src/wallets/in-app/core/authentication/types.ts`, `packages/thirdweb/src/contract/deployment/deploy-deterministic.ts`, `packages/thirdweb/src/contract/deployment/utils/infra.ts`, `packages/thirdweb/src/wallets/injected/index.ts`, `packages/thirdweb/src/wallets/smart/lib/packUserOp.ts`, `packages/thirdweb/src/wallets/in-app/native/helpers/storage/local.ts`, `packages/thirdweb/src/react/web/ui/components/ChainIcon.tsx`, `packages/thirdweb/src/react/web/ui/ConnectWallet/screens/Buy/pay-transactions/BuyTxHistory.tsx`, `packages/thirdweb/src/wallets/in-app/native/helpers/constants.ts`, `packages/thirdweb/src/wallets/in-app/native/helpers/api/fetchers.ts`, `packages/thirdweb/package.json`, `packages/thirdweb/src/react/core/utils/walletIcon.ts`, `pnpm-lock.yaml`

> ✨ Ask PR-Codex anything about this PR by commenting with `/codex {your question}`

<!-- end pr-codex -->
2024-09-23 00:00:12 +00:00

332 lines
12 KiB
JSON

{
"name": "thirdweb",
"version": "5.58.3",
"repository": {
"type": "git",
"url": "git+https://github.com/thirdweb-dev/js.git#main"
},
"license": "Apache-2.0",
"bugs": {
"url": "https://github.com/thirdweb-dev/js/issues"
},
"author": "thirdweb eng <[email protected]>",
"type": "module",
"bin": {
"thirdweb": "./dist/esm/cli/bin.js",
"thirdweb-cli": "./dist/esm/cli/bin.js"
},
"main": "./dist/cjs/exports/thirdweb.js",
"module": "./dist/esm/exports/thirdweb.js",
"types": "./dist/types/exports/thirdweb.d.ts",
"typings": "./dist/types/exports/thirdweb.d.ts",
"exports": {
".": {
"types": "./dist/types/exports/thirdweb.d.ts",
"import": "./dist/esm/exports/thirdweb.js",
"default": "./dist/cjs/exports/thirdweb.js"
},
"./adapters/*": {
"types": "./dist/types/exports/adapters/*.d.ts",
"import": "./dist/esm/exports/adapters/*.js",
"default": "./dist/cjs/exports/adapters/*.js"
},
"./auth": {
"types": "./dist/types/exports/auth.d.ts",
"import": "./dist/esm/exports/auth.js",
"default": "./dist/cjs/exports/auth.js"
},
"./chains": {
"types": "./dist/types/exports/chains.d.ts",
"import": "./dist/esm/exports/chains.js",
"default": "./dist/cjs/exports/chains.js"
},
"./contract": {
"types": "./dist/types/exports/contract.d.ts",
"import": "./dist/esm/exports/contract.js",
"default": "./dist/cjs/exports/contract.js"
},
"./deploys": {
"types": "./dist/types/exports/deploys.d.ts",
"import": "./dist/esm/exports/deploys.js",
"default": "./dist/cjs/exports/deploys.js"
},
"./event": {
"types": "./dist/types/exports/event.d.ts",
"import": "./dist/esm/exports/event.js",
"default": "./dist/cjs/exports/event.js"
},
"./extensions/*": {
"types": "./dist/types/exports/extensions/*.d.ts",
"import": "./dist/esm/exports/extensions/*.js",
"default": "./dist/cjs/exports/extensions/*.js"
},
"./pay": {
"types": "./dist/types/exports/pay.d.ts",
"import": "./dist/esm/exports/pay.js",
"default": "./dist/cjs/exports/pay.js"
},
"./react": {
"types": "./dist/types/exports/react.d.ts",
"import": "./dist/esm/exports/react.js",
"react-native": "./dist/esm/exports/react.native.js",
"default": "./dist/cjs/exports/react.js"
},
"./react-native": {
"types": "./dist/types/exports/react-native.d.ts",
"import": "./dist/esm/exports/react-native.js",
"default": "./dist/cjs/exports/react-native.js"
},
"./rpc": {
"types": "./dist/types/exports/rpc.d.ts",
"import": "./dist/esm/exports/rpc.js",
"default": "./dist/cjs/exports/rpc.js"
},
"./storage": {
"types": "./dist/types/exports/storage.d.ts",
"import": "./dist/esm/exports/storage.js",
"default": "./dist/cjs/exports/storage.js"
},
"./transaction": {
"types": "./dist/types/exports/transaction.d.ts",
"import": "./dist/esm/exports/transaction.js",
"default": "./dist/cjs/exports/transaction.js"
},
"./utils": {
"types": "./dist/types/exports/utils.d.ts",
"import": "./dist/esm/exports/utils.js",
"default": "./dist/cjs/exports/utils.js"
},
"./wallets": {
"types": "./dist/types/exports/wallets.d.ts",
"import": "./dist/esm/exports/wallets.js",
"react-native": "./dist/esm/exports/wallets.native.js",
"default": "./dist/cjs/exports/wallets.js"
},
"./wallets/in-app": {
"types": "./dist/types/exports/wallets/in-app.d.ts",
"import": "./dist/esm/exports/wallets/in-app.js",
"react-native": "./dist/esm/exports/wallets/in-app.native.js",
"default": "./dist/cjs/exports/wallets/in-app.js"
},
"./wallets/*": {
"types": "./dist/types/exports/wallets/*.d.ts",
"import": "./dist/esm/exports/wallets/*.js",
"default": "./dist/cjs/exports/wallets/*.js"
},
"./modules": {
"types": "./dist/types/exports/modules.d.ts",
"import": "./dist/esm/exports/modules.js",
"default": "./dist/cjs/exports/modules.js"
},
"./social": {
"types": "./dist/types/exports/social.d.ts",
"import": "./dist/esm/exports/social.js",
"default": "./dist/cjs/exports/social.js"
},
"./package.json": "./package.json"
},
"typesVersions": {
"*": {
"adapters/*": ["./dist/types/exports/adapters/*.d.ts"],
"auth": ["./dist/types/exports/auth.d.ts"],
"chains": ["./dist/types/exports/chains.d.ts"],
"contract": ["./dist/types/exports/contract.d.ts"],
"deploys": ["./dist/types/exports/deploys.d.ts"],
"event": ["./dist/types/exports/event.d.ts"],
"extensions/*": ["./dist/types/exports/extensions/*.d.ts"],
"pay": ["./dist/types/exports/pay.d.ts"],
"react": ["./dist/types/exports/react.d.ts"],
"react-native": ["./dist/types/exports/react-native.d.ts"],
"rpc": ["./dist/types/exports/rpc.d.ts"],
"storage": ["./dist/types/exports/storage.d.ts"],
"transaction": ["./dist/types/exports/transaction.d.ts"],
"utils": ["./dist/types/exports/utils.d.ts"],
"wallets": ["./dist/types/exports/wallets.d.ts"],
"wallets/*": ["./dist/types/exports/wallets/*.d.ts"],
"modules": ["./dist/types/exports/modules.d.ts"],
"social": ["./dist/types/exports/social.d.ts"]
}
},
"browser": {
"crypto": false
},
"sideEffects": false,
"files": [
"dist/*",
"src/*",
"!**/*.tsbuildinfo",
"!**/*.test.ts",
"!**/*.test.tsx",
"!**/*.test.ts.snap",
"!**/*.test-d.ts",
"!**/*.bench.ts",
"!tsconfig.build.json"
],
"dependencies": {
"@coinbase/wallet-sdk": "4.0.4",
"@emotion/react": "11.13.3",
"@emotion/styled": "11.13.0",
"@google/model-viewer": "2.1.1",
"@noble/curves": "1.4.0",
"@noble/hashes": "1.4.0",
"@passwordless-id/webauthn": "^1.6.1",
"@radix-ui/react-dialog": "1.1.1",
"@radix-ui/react-focus-scope": "1.1.0",
"@radix-ui/react-icons": "1.3.0",
"@radix-ui/react-tooltip": "1.1.2",
"@tanstack/react-query": "5.56.2",
"@walletconnect/ethereum-provider": "2.16.2",
"@walletconnect/sign-client": "2.16.2",
"abitype": "1.0.5",
"fuse.js": "7.0.0",
"input-otp": "^1.2.4",
"mipd": "0.0.7",
"uqr": "0.1.2",
"viem": "2.21.11"
},
"peerDependencies": {
"@aws-sdk/client-lambda": "^3",
"@aws-sdk/credential-providers": "^3",
"@coinbase/wallet-mobile-sdk": "^1",
"@mobile-wallet-protocol/client": "0.0.3",
"@react-native-async-storage/async-storage": "^1 || ^2",
"ethers": "^5 || ^6",
"expo-linking": "^6",
"expo-web-browser": "^13",
"react": ">=18",
"react-native": "*",
"react-native-aes-gcm-crypto": "^0.2",
"react-native-quick-crypto": ">=0.7.0-rc.6 || >=0.7",
"react-native-svg": "^15",
"typescript": ">=5.0.4"
},
"peerDependenciesMeta": {
"react": {
"optional": true
},
"react-native": {
"optional": true
},
"ethers": {
"optional": true
},
"typescript": {
"optional": true
},
"react-native-aes-gcm-crypto": {
"optional": true
},
"expo-linking": {
"optional": true
},
"expo-web-browser": {
"optional": true
},
"react-native-quick-crypto": {
"optional": true
},
"react-native-passkey": {
"optional": true
},
"react-native-svg": {
"optional": true
},
"@aws-sdk/client-lambda": {
"optional": true
},
"@aws-sdk/credential-providers": {
"optional": true
},
"@react-native-async-storage/async-storage": {
"optional": true
},
"@coinbase/wallet-mobile-sdk": {
"optional": true
},
"@mobile-wallet-protocol/client": {
"optional": true
}
},
"scripts": {
"bench:compare": "bun run ./benchmarks/run.ts",
"bench": "vitest -c ./test/vitest.config.ts bench",
"format": "biome format ./src --write",
"lint": "knip && biome check ./src && tsc --project ./tsconfig.build.json --module esnext --noEmit",
"fix": "biome check ./src --fix",
"knip": "knip",
"build:generate": "bun scripts/generate/generate.ts",
"build:generate-wallets": "bun scripts/wallets/generate.ts",
"dev": "tsc --project ./tsconfig.build.json --module es2020 --outDir ./dist/esm --watch",
"dev:cjs": "printf '{\"type\":\"commonjs\"}' > ./dist/cjs/package.json && tsc --noCheck --project ./tsconfig.build.json --module commonjs --outDir ./dist/cjs --verbatimModuleSyntax false --watch",
"dev:esm": "printf '{\"type\": \"module\",\"sideEffects\":false}' > ./dist/esm/package.json && tsc --noCheck --project ./tsconfig.build.json --module es2020 --outDir ./dist/esm --watch",
"build": "pnpm clean && pnpm build:types && pnpm build:cjs && pnpm build:esm",
"build:cjs": "tsc --noCheck --project ./tsconfig.build.json --module commonjs --outDir ./dist/cjs --verbatimModuleSyntax false && printf '{\"type\":\"commonjs\"}' > ./dist/cjs/package.json",
"build:esm": "tsc --noCheck --project ./tsconfig.build.json --module es2020 --outDir ./dist/esm && printf '{\"type\": \"module\",\"sideEffects\":false}' > ./dist/esm/package.json",
"build:types": "tsc --project ./tsconfig.build.json --module esnext --declarationDir ./dist/types --emitDeclarationOnly --declaration --declarationMap",
"clean": "rimraf dist",
"size": "size-limit",
"test:watch": "vitest -c ./test/vitest.config.ts dev",
"test": "vitest run -c ./test/vitest.config.ts --coverage",
"test:cov": "vitest dev -c ./test/vitest.config.ts --coverage",
"test:dev": "vitest run -c ./test/vitest.config.ts",
"test:react": "vitest run -c ./test/vitest.config.ts dev --ui src/react",
"typedoc": "bun run scripts/typedoc.mjs",
"update-version": "node scripts/version.mjs",
"storybook": "storybook dev -p 6006",
"build-storybook": "storybook build"
},
"engines": {
"node": ">=18"
},
"devDependencies": {
"@aws-sdk/client-lambda": "3.656.0",
"@aws-sdk/credential-providers": "3.654.0",
"@biomejs/biome": "1.9.2",
"@chromatic-com/storybook": "2.0.2",
"@codspeed/vitest-plugin": "3.1.1",
"@coinbase/wallet-mobile-sdk": "1.1.2",
"@mobile-wallet-protocol/client": "0.0.3",
"@react-native-async-storage/async-storage": "1.24.0",
"@size-limit/preset-big-lib": "11.1.5",
"@storybook/addon-essentials": "8.3.2",
"@storybook/addon-interactions": "8.3.2",
"@storybook/addon-links": "8.3.2",
"@storybook/addon-onboarding": "8.3.2",
"@storybook/react": "8.3.2",
"@storybook/react-vite": "8.3.2",
"@storybook/test": "8.3.2",
"@testing-library/jest-dom": "^6.4.7",
"@testing-library/react": "^16.0.0",
"@testing-library/user-event": "^14.5.2",
"@types/cross-spawn": "^6.0.6",
"@types/react": "^18.3.8",
"@viem/anvil": "0.0.10",
"@vitejs/plugin-react": "^4.3.1",
"@vitest/coverage-v8": "2.1.1",
"@vitest/ui": "2.1.1",
"cross-spawn": "7.0.3",
"dotenv-mono": "^1.3.14",
"ethers5": "npm:ethers@5",
"ethers6": "npm:ethers@6",
"expo-linking": "6.3.1",
"expo-web-browser": "13.0.3",
"happy-dom": "^15.7.4",
"knip": "^5.30.4",
"prettier": "^3.3.2",
"react": "18.3.1",
"react-native": "0.75.3",
"react-native-aes-gcm-crypto": "0.2.2",
"react-native-passkey": "3.0.0-beta2",
"react-native-quick-crypto": "0.7.4",
"react-native-svg": "15.7.1",
"rimraf": "6.0.1",
"sharp": "^0.33.5",
"size-limit": "11.1.5",
"storybook": "8.3.2",
"typedoc": "0.26.7",
"typescript": "5.6.2",
"vite": "5.4.7",
"vitest": "2.1.1"
}
}