viem 0.0.0-main.20230913T050526 → 0.0.0-main.20230913T210225

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (133) hide show
  1. package/_cjs/{abi.js → abi/index.js} +9 -9
  2. package/_cjs/abi/index.js.map +1 -0
  3. package/_cjs/chains/{utils.js → utils/index.js} +5 -5
  4. package/_cjs/chains/utils/index.js.map +1 -0
  5. package/_cjs/{contract.js → contract/index.js} +25 -25
  6. package/_cjs/contract/index.js.map +1 -0
  7. package/_cjs/{ens.js → ens/index.js} +9 -9
  8. package/_cjs/ens/index.js.map +1 -0
  9. package/_cjs/errors/node.js +11 -11
  10. package/_cjs/errors/node.js.map +1 -1
  11. package/_cjs/errors/rpc.js +18 -18
  12. package/_cjs/errors/rpc.js.map +1 -1
  13. package/_cjs/errors/version.js +1 -1
  14. package/_cjs/{public.js → public/index.js} +29 -29
  15. package/_cjs/public/index.js.map +1 -0
  16. package/_cjs/{test.js → test/index.js} +29 -29
  17. package/_cjs/test/index.js.map +1 -0
  18. package/_cjs/{wallet.js → wallet/index.js} +11 -11
  19. package/_cjs/wallet/index.js.map +1 -0
  20. package/_cjs/{window.js → window/window.js} +1 -1
  21. package/_cjs/window/window.js.map +1 -0
  22. package/_esm/abi/index.js +7 -0
  23. package/_esm/abi/index.js.map +1 -0
  24. package/_esm/chains/utils/index.js +5 -0
  25. package/_esm/chains/utils/index.js.map +1 -0
  26. package/_esm/contract/index.js +26 -0
  27. package/_esm/contract/index.js.map +1 -0
  28. package/_esm/ens/index.js +9 -0
  29. package/_esm/ens/index.js.map +1 -0
  30. package/_esm/errors/node.js +22 -11
  31. package/_esm/errors/node.js.map +1 -1
  32. package/_esm/errors/rpc.js +36 -18
  33. package/_esm/errors/rpc.js.map +1 -1
  34. package/_esm/errors/version.js +1 -1
  35. package/_esm/public/index.js +30 -0
  36. package/_esm/public/index.js.map +1 -0
  37. package/_esm/test/index.js +30 -0
  38. package/_esm/test/index.js.map +1 -0
  39. package/_esm/wallet/index.js +12 -0
  40. package/_esm/wallet/index.js.map +1 -0
  41. package/_esm/window/window.js +2 -0
  42. package/_esm/window/window.js.map +1 -0
  43. package/_types/{abi.d.ts → abi/index.d.ts} +5 -5
  44. package/_types/abi/index.d.ts.map +1 -0
  45. package/_types/chains/definitions/base.d.ts +14 -14
  46. package/_types/chains/definitions/baseGoerli.d.ts +14 -14
  47. package/_types/chains/definitions/celo.d.ts +15 -15
  48. package/_types/chains/definitions/celoAlfajores.d.ts +15 -15
  49. package/_types/chains/definitions/celoCannoli.d.ts +15 -15
  50. package/_types/chains/definitions/optimism.d.ts +14 -14
  51. package/_types/chains/definitions/optimismGoerli.d.ts +14 -14
  52. package/_types/chains/definitions/zora.d.ts +14 -14
  53. package/_types/chains/definitions/zoraTestnet.d.ts +14 -14
  54. package/_types/chains/{utils.d.ts → utils/index.d.ts} +7 -7
  55. package/_types/chains/utils/index.d.ts.map +1 -0
  56. package/_types/{contract.d.ts → contract/index.d.ts} +26 -26
  57. package/_types/contract/index.d.ts.map +1 -0
  58. package/_types/ens/index.d.ts +9 -0
  59. package/_types/ens/index.d.ts.map +1 -0
  60. package/_types/errors/version.d.ts +1 -1
  61. package/_types/public/index.d.ts +33 -0
  62. package/_types/public/index.d.ts.map +1 -0
  63. package/_types/test/index.d.ts +29 -0
  64. package/_types/test/index.d.ts.map +1 -0
  65. package/_types/utils/formatters/transaction.d.ts +1 -1
  66. package/_types/utils/formatters/transactionRequest.d.ts +1 -1
  67. package/_types/wallet/index.d.ts +11 -0
  68. package/_types/wallet/index.d.ts.map +1 -0
  69. package/_types/window/window.d.ts +2 -0
  70. package/_types/window/window.d.ts.map +1 -0
  71. package/{abi.ts → abi/index.ts} +15 -13
  72. package/abi/package.json +6 -0
  73. package/accounts/package.json +6 -0
  74. package/actions/package.json +6 -0
  75. package/chains/package.json +6 -0
  76. package/chains/{utils.ts → utils/index.ts} +6 -6
  77. package/chains/utils/package.json +6 -0
  78. package/clients/package.json +6 -0
  79. package/{contract.ts → contract/index.ts} +27 -25
  80. package/contract/package.json +6 -0
  81. package/{ens.ts → ens/index.ts} +8 -8
  82. package/ens/package.json +6 -0
  83. package/errors/version.ts +1 -1
  84. package/package.json +25 -25
  85. package/{public.ts → public/index.ts} +30 -28
  86. package/public/package.json +6 -0
  87. package/test/index.ts +85 -0
  88. package/test/package.json +6 -0
  89. package/utils/package.json +6 -0
  90. package/{wallet.ts → wallet/index.ts} +15 -10
  91. package/wallet/package.json +6 -0
  92. package/window/package.json +6 -0
  93. package/window/window.ts +1 -0
  94. package/CHANGELOG.md +0 -9
  95. package/_cjs/abi.js.map +0 -1
  96. package/_cjs/chains/utils.js.map +0 -1
  97. package/_cjs/contract.js.map +0 -1
  98. package/_cjs/ens.js.map +0 -1
  99. package/_cjs/public.js.map +0 -1
  100. package/_cjs/test.js.map +0 -1
  101. package/_cjs/wallet.js.map +0 -1
  102. package/_cjs/window.js.map +0 -1
  103. package/_esm/abi.js +0 -6
  104. package/_esm/abi.js.map +0 -1
  105. package/_esm/chains/utils.js +0 -5
  106. package/_esm/chains/utils.js.map +0 -1
  107. package/_esm/contract.js +0 -25
  108. package/_esm/contract.js.map +0 -1
  109. package/_esm/ens.js +0 -9
  110. package/_esm/ens.js.map +0 -1
  111. package/_esm/public.js +0 -29
  112. package/_esm/public.js.map +0 -1
  113. package/_esm/test.js +0 -29
  114. package/_esm/test.js.map +0 -1
  115. package/_esm/wallet.js +0 -11
  116. package/_esm/wallet.js.map +0 -1
  117. package/_esm/window.js +0 -2
  118. package/_esm/window.js.map +0 -1
  119. package/_types/abi.d.ts.map +0 -1
  120. package/_types/chains/utils.d.ts.map +0 -1
  121. package/_types/contract.d.ts.map +0 -1
  122. package/_types/ens.d.ts +0 -9
  123. package/_types/ens.d.ts.map +0 -1
  124. package/_types/public.d.ts +0 -33
  125. package/_types/public.d.ts.map +0 -1
  126. package/_types/test.d.ts +0 -29
  127. package/_types/test.d.ts.map +0 -1
  128. package/_types/wallet.d.ts +0 -11
  129. package/_types/wallet.d.ts.map +0 -1
  130. package/_types/window.d.ts +0 -2
  131. package/_types/window.d.ts.map +0 -1
  132. package/test.ts +0 -83
  133. package/window.ts +0 -1
@@ -1,28 +1,30 @@
1
+ // TODO(v2): Remove this entrypoint. Favor importing from root entrypoint (`viem`).
2
+
1
3
  export {
2
4
  type CreateContractEventFilterParameters,
3
5
  type CreateContractEventFilterReturnType,
4
6
  createContractEventFilter,
5
- } from './actions/public/createContractEventFilter.js'
7
+ } from '../actions/public/createContractEventFilter.js'
6
8
  export {
7
9
  type EstimateContractGasParameters,
8
10
  type EstimateContractGasReturnType,
9
11
  estimateContractGas,
10
- } from './actions/public/estimateContractGas.js'
12
+ } from '../actions/public/estimateContractGas.js'
11
13
  export {
12
14
  type GetBytecodeParameters,
13
15
  type GetBytecodeReturnType,
14
16
  getBytecode,
15
- } from './actions/public/getBytecode.js'
17
+ } from '../actions/public/getBytecode.js'
16
18
  export {
17
19
  type GetStorageAtParameters,
18
20
  type GetStorageAtReturnType,
19
21
  getStorageAt,
20
- } from './actions/public/getStorageAt.js'
22
+ } from '../actions/public/getStorageAt.js'
21
23
  export {
22
24
  type MulticallParameters,
23
25
  type MulticallReturnType,
24
26
  multicall,
25
- } from './actions/public/multicall.js'
27
+ } from '../actions/public/multicall.js'
26
28
  export type {
27
29
  WatchEventOnLogsFn,
28
30
  /** @deprecated - use `WatchEventOnLogsFn` instead. */
@@ -30,81 +32,81 @@ export type {
30
32
  WatchEventOnLogsParameter,
31
33
  /** @deprecated - use `WatchEventOnLogsParameter` instead. */
32
34
  WatchEventOnLogsParameter as OnLogsParameter,
33
- } from './actions/public/watchEvent.js'
35
+ } from '../actions/public/watchEvent.js'
34
36
  export {
35
37
  type ReadContractParameters,
36
38
  type ReadContractReturnType,
37
39
  readContract,
38
- } from './actions/public/readContract.js'
40
+ } from '../actions/public/readContract.js'
39
41
  export {
40
42
  type SimulateContractParameters,
41
43
  type SimulateContractReturnType,
42
44
  simulateContract,
43
- } from './actions/public/simulateContract.js'
45
+ } from '../actions/public/simulateContract.js'
44
46
  export {
45
47
  type WatchContractEventParameters,
46
48
  watchContractEvent,
47
- } from './actions/public/watchContractEvent.js'
49
+ } from '../actions/public/watchContractEvent.js'
48
50
  export {
49
51
  type DeployContractParameters,
50
52
  type DeployContractReturnType,
51
53
  deployContract,
52
- } from './actions/wallet/deployContract.js'
54
+ } from '../actions/wallet/deployContract.js'
53
55
  export {
54
56
  type WriteContractParameters,
55
57
  type WriteContractReturnType,
56
58
  writeContract,
57
- } from './actions/wallet/writeContract.js'
59
+ } from '../actions/wallet/writeContract.js'
58
60
  export {
59
61
  type DecodeAbiParametersReturnType,
60
62
  decodeAbiParameters,
61
- } from './utils/abi/decodeAbiParameters.js'
63
+ } from '../utils/abi/decodeAbiParameters.js'
62
64
  export {
63
65
  type DecodeErrorResultParameters,
64
66
  type DecodeErrorResultReturnType,
65
67
  decodeErrorResult,
66
- } from './utils/abi/decodeErrorResult.js'
68
+ } from '../utils/abi/decodeErrorResult.js'
67
69
  export {
68
70
  type DecodeEventLogParameters,
69
71
  type DecodeEventLogReturnType,
70
72
  decodeEventLog,
71
- } from './utils/abi/decodeEventLog.js'
73
+ } from '../utils/abi/decodeEventLog.js'
72
74
  export {
73
75
  type DecodeFunctionDataParameters,
74
76
  decodeFunctionData,
75
- } from './utils/abi/decodeFunctionData.js'
77
+ } from '../utils/abi/decodeFunctionData.js'
76
78
  export {
77
79
  type DecodeFunctionResultParameters,
78
80
  type DecodeFunctionResultReturnType,
79
81
  decodeFunctionResult,
80
- } from './utils/abi/decodeFunctionResult.js'
82
+ } from '../utils/abi/decodeFunctionResult.js'
81
83
  export {
82
84
  type EncodeAbiParametersReturnType,
83
85
  encodeAbiParameters,
84
- } from './utils/abi/encodeAbiParameters.js'
86
+ } from '../utils/abi/encodeAbiParameters.js'
85
87
  export {
86
88
  type EncodeDeployDataParameters,
87
89
  encodeDeployData,
88
- } from './utils/abi/encodeDeployData.js'
90
+ } from '../utils/abi/encodeDeployData.js'
89
91
  export {
90
92
  type EncodeErrorResultParameters,
91
93
  encodeErrorResult,
92
- } from './utils/abi/encodeErrorResult.js'
94
+ } from '../utils/abi/encodeErrorResult.js'
93
95
  export {
94
96
  type EncodeEventTopicsParameters,
95
97
  encodeEventTopics,
96
- } from './utils/abi/encodeEventTopics.js'
98
+ } from '../utils/abi/encodeEventTopics.js'
97
99
  export {
98
100
  type EncodeFunctionDataParameters,
99
101
  encodeFunctionData,
100
- } from './utils/abi/encodeFunctionData.js'
102
+ } from '../utils/abi/encodeFunctionData.js'
101
103
  export {
102
104
  type EncodeFunctionResultParameters,
103
105
  encodeFunctionResult,
104
- } from './utils/abi/encodeFunctionResult.js'
106
+ } from '../utils/abi/encodeFunctionResult.js'
105
107
  export {
106
108
  type GetAbiItemParameters,
107
109
  getAbiItem,
108
- } from './utils/abi/getAbiItem.js'
109
- export { formatAbiItemWithArgs } from './utils/abi/formatAbiItemWithArgs.js'
110
- export { formatAbiItem } from './utils/abi/formatAbiItem.js'
110
+ } from '../utils/abi/getAbiItem.js'
111
+ export { formatAbiItemWithArgs } from '../utils/abi/formatAbiItemWithArgs.js'
112
+ export { formatAbiItem } from '../utils/abi/formatAbiItem.js'
@@ -0,0 +1,6 @@
1
+ {
2
+ "type": "module",
3
+ "types": "../_types/contract/index.d.ts",
4
+ "module": "../_esm/contract/index.js",
5
+ "main": "../_cjs/contract/index.js"
6
+ }
@@ -1,28 +1,28 @@
1
- export { normalize } from './utils/ens/normalize.js'
1
+ export { normalize } from '../utils/ens/normalize.js'
2
2
  export {
3
3
  type GetEnsAddressParameters,
4
4
  type GetEnsAddressReturnType,
5
5
  getEnsAddress,
6
- } from './actions/ens/getEnsAddress.js'
6
+ } from '../actions/ens/getEnsAddress.js'
7
7
  export {
8
8
  type GetEnsAvatarParameters,
9
9
  type GetEnsAvatarReturnType,
10
10
  getEnsAvatar,
11
- } from './actions/ens/getEnsAvatar.js'
11
+ } from '../actions/ens/getEnsAvatar.js'
12
12
  export {
13
13
  type GetEnsNameParameters,
14
14
  type GetEnsNameReturnType,
15
15
  getEnsName,
16
- } from './actions/ens/getEnsName.js'
16
+ } from '../actions/ens/getEnsName.js'
17
17
  export {
18
18
  type GetEnsResolverParameters,
19
19
  type GetEnsResolverReturnType,
20
20
  getEnsResolver,
21
- } from './actions/ens/getEnsResolver.js'
21
+ } from '../actions/ens/getEnsResolver.js'
22
22
  export {
23
23
  type GetEnsTextParameters,
24
24
  type GetEnsTextReturnType,
25
25
  getEnsText,
26
- } from './actions/ens/getEnsText.js'
27
- export { labelhash } from './utils/ens/labelhash.js'
28
- export { namehash } from './utils/ens/namehash.js'
26
+ } from '../actions/ens/getEnsText.js'
27
+ export { labelhash } from '../utils/ens/labelhash.js'
28
+ export { namehash } from '../utils/ens/namehash.js'
@@ -0,0 +1,6 @@
1
+ {
2
+ "type": "module",
3
+ "types": "../_types/ens/index.d.ts",
4
+ "module": "../_esm/ens/index.js",
5
+ "main": "../_cjs/ens/index.js"
6
+ }
package/errors/version.ts CHANGED
@@ -1 +1 @@
1
- export const version = '0.0.0-main.20230913T050526'
1
+ export const version = '0.0.0-main.20230913T210225'
package/package.json CHANGED
@@ -1,7 +1,7 @@
1
1
  {
2
2
  "name": "viem",
3
3
  "description": "TypeScript Interface for Ethereum",
4
- "version": "0.0.0-main.20230913T050526",
4
+ "version": "0.0.0-main.20230913T210225",
5
5
  "type": "module",
6
6
  "main": "./_cjs/index.js",
7
7
  "module": "./_esm/index.js",
@@ -23,9 +23,9 @@
23
23
  "default": "./_cjs/index.js"
24
24
  },
25
25
  "./abi": {
26
- "types": "./_types/abi.d.ts",
27
- "import": "./_esm/abi.js",
28
- "default": "./_cjs/abi.js"
26
+ "types": "./_types/abi/index.d.ts",
27
+ "import": "./_esm/abi/index.js",
28
+ "default": "./_cjs/abi/index.js"
29
29
  },
30
30
  "./accounts": {
31
31
  "types": "./_types/accounts/index.d.ts",
@@ -43,29 +43,29 @@
43
43
  "default": "./_cjs/chains/index.js"
44
44
  },
45
45
  "./chains/utils": {
46
- "types": "./_types/chains/utils.d.ts",
47
- "import": "./_esm/chains/utils.js",
48
- "default": "./_cjs/chains/utils.js"
46
+ "types": "./_types/chains/utils/index.d.ts",
47
+ "import": "./_esm/chains/utils/index.js",
48
+ "default": "./_cjs/chains/utils/index.js"
49
49
  },
50
50
  "./contract": {
51
- "types": "./_types/contract.d.ts",
52
- "import": "./_esm/contract.js",
53
- "default": "./_cjs/contract.js"
51
+ "types": "./_types/contract/index.d.ts",
52
+ "import": "./_esm/contract/index.js",
53
+ "default": "./_cjs/contract/index.js"
54
54
  },
55
55
  "./ens": {
56
- "types": "./_types/ens.d.ts",
57
- "import": "./_esm/ens.js",
58
- "default": "./_cjs/ens.js"
56
+ "types": "./_types/ens/index.d.ts",
57
+ "import": "./_esm/ens/index.js",
58
+ "default": "./_cjs/ens/index.js"
59
59
  },
60
60
  "./public": {
61
- "types": "./_types/public.d.ts",
62
- "import": "./_esm/public.js",
63
- "default": "./_cjs/public.js"
61
+ "types": "./_types/public/index.d.ts",
62
+ "import": "./_esm/public/index.js",
63
+ "default": "./_cjs/public/index.js"
64
64
  },
65
65
  "./test": {
66
- "types": "./_types/test.d.ts",
67
- "import": "./_esm/test.js",
68
- "default": "./_cjs/test.js"
66
+ "types": "./_types/test/index.d.ts",
67
+ "import": "./_esm/test/index.js",
68
+ "default": "./_cjs/test/index.js"
69
69
  },
70
70
  "./utils": {
71
71
  "types": "./_types/utils/index.d.ts",
@@ -73,14 +73,14 @@
73
73
  "default": "./_cjs/utils/index.js"
74
74
  },
75
75
  "./wallet": {
76
- "types": "./_types/wallet.d.ts",
77
- "import": "./_esm/wallet.js",
78
- "default": "./_cjs/wallet.js"
76
+ "types": "./_types/wallet/index.d.ts",
77
+ "import": "./_esm/wallet/index.js",
78
+ "default": "./_cjs/wallet/index.js"
79
79
  },
80
80
  "./window": {
81
- "types": "./_types/window.d.ts",
82
- "import": "./_esm/window.js",
83
- "default": "./_cjs/window.js"
81
+ "types": "./_types/window/index.d.ts",
82
+ "import": "./_esm/window/index.js",
83
+ "default": "./_cjs/window/index.js"
84
84
  },
85
85
  "./package.json": "./package.json"
86
86
  },
@@ -1,127 +1,129 @@
1
+ // TODO(v2): Remove this entrypoint. Favor importing from actions entrypoint (`viem/actions`).
2
+
1
3
  export {
2
4
  call,
3
5
  type CallParameters,
4
6
  type CallReturnType,
5
- } from './actions/public/call.js'
7
+ } from '../actions/public/call.js'
6
8
  export {
7
9
  createBlockFilter,
8
10
  type CreateBlockFilterReturnType,
9
- } from './actions/public/createBlockFilter.js'
11
+ } from '../actions/public/createBlockFilter.js'
10
12
  export {
11
13
  createEventFilter,
12
14
  type CreateEventFilterParameters,
13
15
  type CreateEventFilterReturnType,
14
- } from './actions/public/createEventFilter.js'
16
+ } from '../actions/public/createEventFilter.js'
15
17
  export {
16
18
  createPendingTransactionFilter,
17
19
  type CreatePendingTransactionFilterReturnType,
18
- } from './actions/public/createPendingTransactionFilter.js'
20
+ } from '../actions/public/createPendingTransactionFilter.js'
19
21
  export {
20
22
  estimateGas,
21
23
  type EstimateGasParameters,
22
24
  type EstimateGasReturnType,
23
- } from './actions/public/estimateGas.js'
25
+ } from '../actions/public/estimateGas.js'
24
26
  export {
25
27
  getBalance,
26
28
  type GetBalanceParameters,
27
29
  type GetBalanceReturnType,
28
- } from './actions/public/getBalance.js'
30
+ } from '../actions/public/getBalance.js'
29
31
  export {
30
32
  getBlock,
31
33
  type GetBlockParameters,
32
34
  type GetBlockReturnType,
33
- } from './actions/public/getBlock.js'
35
+ } from '../actions/public/getBlock.js'
34
36
  export {
35
37
  getBlockNumber,
36
38
  getBlockNumberCache,
37
39
  type GetBlockNumberParameters,
38
40
  type GetBlockNumberReturnType,
39
- } from './actions/public/getBlockNumber.js'
41
+ } from '../actions/public/getBlockNumber.js'
40
42
  export {
41
43
  getBlockTransactionCount,
42
44
  type GetBlockTransactionCountParameters,
43
45
  type GetBlockTransactionCountReturnType,
44
- } from './actions/public/getBlockTransactionCount.js'
46
+ } from '../actions/public/getBlockTransactionCount.js'
45
47
  export {
46
48
  getBytecode,
47
49
  type GetBytecodeParameters,
48
50
  type GetBytecodeReturnType,
49
- } from './actions/public/getBytecode.js'
50
- export { getChainId } from './actions/public/getChainId.js'
51
+ } from '../actions/public/getBytecode.js'
52
+ export { getChainId } from '../actions/public/getChainId.js'
51
53
  export {
52
54
  getFeeHistory,
53
55
  type GetFeeHistoryParameters,
54
56
  type GetFeeHistoryReturnType,
55
- } from './actions/public/getFeeHistory.js'
57
+ } from '../actions/public/getFeeHistory.js'
56
58
  export {
57
59
  estimateFeesPerGas,
58
60
  type EstimateFeesPerGasParameters,
59
61
  type EstimateFeesPerGasReturnType,
60
- } from './actions/public/estimateFeesPerGas.js'
62
+ } from '../actions/public/estimateFeesPerGas.js'
61
63
  export {
62
64
  getFilterChanges,
63
65
  type GetFilterChangesParameters,
64
66
  type GetFilterChangesReturnType,
65
- } from './actions/public/getFilterChanges.js'
67
+ } from '../actions/public/getFilterChanges.js'
66
68
  export {
67
69
  getFilterLogs,
68
70
  type GetFilterLogsParameters,
69
71
  type GetFilterLogsReturnType,
70
- } from './actions/public/getFilterLogs.js'
71
- export { getLogs } from './actions/public/getLogs.js'
72
+ } from '../actions/public/getFilterLogs.js'
73
+ export { getLogs } from '../actions/public/getLogs.js'
72
74
  export {
73
75
  getGasPrice,
74
76
  type GetGasPriceReturnType,
75
- } from './actions/public/getGasPrice.js'
77
+ } from '../actions/public/getGasPrice.js'
76
78
  export {
77
79
  estimateMaxPriorityFeePerGas,
78
80
  type EstimateMaxPriorityFeePerGasParameters,
79
81
  type EstimateMaxPriorityFeePerGasReturnType,
80
- } from './actions/public/estimateMaxPriorityFeePerGas.js'
82
+ } from '../actions/public/estimateMaxPriorityFeePerGas.js'
81
83
  export {
82
84
  getTransaction,
83
85
  type GetTransactionParameters,
84
86
  type GetTransactionReturnType,
85
- } from './actions/public/getTransaction.js'
87
+ } from '../actions/public/getTransaction.js'
86
88
  export {
87
89
  getTransactionConfirmations,
88
90
  type GetTransactionConfirmationsParameters,
89
91
  type GetTransactionConfirmationsReturnType,
90
- } from './actions/public/getTransactionConfirmations.js'
92
+ } from '../actions/public/getTransactionConfirmations.js'
91
93
  export {
92
94
  getTransactionCount,
93
95
  type GetTransactionCountParameters,
94
96
  type GetTransactionCountReturnType,
95
- } from './actions/public/getTransactionCount.js'
97
+ } from '../actions/public/getTransactionCount.js'
96
98
  export {
97
99
  getTransactionReceipt,
98
100
  type GetTransactionReceiptParameters,
99
101
  type GetTransactionReceiptReturnType,
100
- } from './actions/public/getTransactionReceipt.js'
102
+ } from '../actions/public/getTransactionReceipt.js'
101
103
  export {
102
104
  uninstallFilter,
103
105
  type UninstallFilterParameters,
104
106
  type UninstallFilterReturnType,
105
- } from './actions/public/uninstallFilter.js'
107
+ } from '../actions/public/uninstallFilter.js'
106
108
  export {
107
109
  waitForTransactionReceipt,
108
110
  type ReplacementReason,
109
111
  type ReplacementReturnType,
110
112
  type WaitForTransactionReceiptParameters,
111
113
  type WaitForTransactionReceiptReturnType,
112
- } from './actions/public/waitForTransactionReceipt.js'
114
+ } from '../actions/public/waitForTransactionReceipt.js'
113
115
  export {
114
116
  watchBlockNumber,
115
117
  type OnBlockNumberFn,
116
118
  type OnBlockNumberParameter,
117
119
  type WatchBlockNumberParameters,
118
- } from './actions/public/watchBlockNumber.js'
120
+ } from '../actions/public/watchBlockNumber.js'
119
121
  export {
120
122
  watchBlocks,
121
123
  type OnBlock,
122
124
  type OnBlockParameter,
123
125
  type WatchBlocksParameters,
124
- } from './actions/public/watchBlocks.js'
126
+ } from '../actions/public/watchBlocks.js'
125
127
  export {
126
128
  watchEvent,
127
129
  type WatchEventOnLogsFn,
@@ -130,10 +132,10 @@ export {
130
132
  type WatchEventOnLogsParameter,
131
133
  /** @deprecated - use `WatchEventOnLogsParameter` instead. */
132
134
  type WatchEventOnLogsParameter as OnLogsParameter,
133
- } from './actions/public/watchEvent.js'
135
+ } from '../actions/public/watchEvent.js'
134
136
  export {
135
137
  watchPendingTransactions,
136
138
  type OnTransactionsFn,
137
139
  type OnTransactionsParameter,
138
140
  type WatchPendingTransactionsParameters,
139
- } from './actions/public/watchPendingTransactions.js'
141
+ } from '../actions/public/watchPendingTransactions.js'
@@ -0,0 +1,6 @@
1
+ {
2
+ "type": "module",
3
+ "types": "../_types/public/index.d.ts",
4
+ "module": "../_esm/public/index.js",
5
+ "main": "../_cjs/public/index.js"
6
+ }
package/test/index.ts ADDED
@@ -0,0 +1,85 @@
1
+ // TODO(v2): Remove this entrypoint. Favor importing from actions entrypoint (`viem/actions`).
2
+
3
+ export {
4
+ dropTransaction,
5
+ type DropTransactionParameters,
6
+ } from '../actions/test/dropTransaction.js'
7
+ export {
8
+ getAutomine,
9
+ type GetAutomineReturnType,
10
+ } from '../actions/test/getAutomine.js'
11
+ export {
12
+ getTxpoolContent,
13
+ type GetTxpoolContentReturnType,
14
+ } from '../actions/test/getTxpoolContent.js'
15
+ export {
16
+ getTxpoolStatus,
17
+ type GetTxpoolStatusReturnType,
18
+ } from '../actions/test/getTxpoolStatus.js'
19
+ export {
20
+ impersonateAccount,
21
+ type ImpersonateAccountParameters,
22
+ } from '../actions/test/impersonateAccount.js'
23
+ export {
24
+ increaseTime,
25
+ type IncreaseTimeParameters,
26
+ } from '../actions/test/increaseTime.js'
27
+ export {
28
+ inspectTxpool,
29
+ type InspectTxpoolReturnType,
30
+ } from '../actions/test/inspectTxpool.js'
31
+ export { mine, type MineParameters } from '../actions/test/mine.js'
32
+ export { removeBlockTimestampInterval } from '../actions/test/removeBlockTimestampInterval.js'
33
+ export { reset, type ResetParameters } from '../actions/test/reset.js'
34
+ export { revert, type RevertParameters } from '../actions/test/revert.js'
35
+ export {
36
+ sendUnsignedTransaction,
37
+ type SendUnsignedTransactionParameters,
38
+ type SendUnsignedTransactionReturnType,
39
+ } from '../actions/test/sendUnsignedTransaction.js'
40
+ export { setAutomine } from '../actions/test/setAutomine.js'
41
+ export {
42
+ setBalance,
43
+ type SetBalanceParameters,
44
+ } from '../actions/test/setBalance.js'
45
+ export {
46
+ setBlockGasLimit,
47
+ type SetBlockGasLimitParameters,
48
+ } from '../actions/test/setBlockGasLimit.js'
49
+ export {
50
+ setBlockTimestampInterval,
51
+ type SetBlockTimestampIntervalParameters,
52
+ } from '../actions/test/setBlockTimestampInterval.js'
53
+ export { setCode, type SetCodeParameters } from '../actions/test/setCode.js'
54
+ export {
55
+ setCoinbase,
56
+ type SetCoinbaseParameters,
57
+ } from '../actions/test/setCoinbase.js'
58
+ export {
59
+ setIntervalMining,
60
+ type SetIntervalMiningParameters,
61
+ } from '../actions/test/setIntervalMining.js'
62
+ export { setLoggingEnabled } from '../actions/test/setLoggingEnabled.js'
63
+ export {
64
+ setMinGasPrice,
65
+ type SetMinGasPriceParameters,
66
+ } from '../actions/test/setMinGasPrice.js'
67
+ export {
68
+ setNextBlockBaseFeePerGas,
69
+ type SetNextBlockBaseFeePerGasParameters,
70
+ } from '../actions/test/setNextBlockBaseFeePerGas.js'
71
+ export {
72
+ setNextBlockTimestamp,
73
+ type SetNextBlockTimestampParameters,
74
+ } from '../actions/test/setNextBlockTimestamp.js'
75
+ export { setNonce, type SetNonceParameters } from '../actions/test/setNonce.js'
76
+ export {
77
+ setStorageAt,
78
+ type SetStorageAtParameters,
79
+ } from '../actions/test/setStorageAt.js'
80
+ export { snapshot } from '../actions/test/snapshot.js'
81
+ export { setRpcUrl } from '../actions/test/setRpcUrl.js'
82
+ export {
83
+ stopImpersonatingAccount,
84
+ type StopImpersonatingAccountParameters,
85
+ } from '../actions/test/stopImpersonatingAccount.js'
@@ -0,0 +1,6 @@
1
+ {
2
+ "type": "module",
3
+ "types": "../_types/test/index.d.ts",
4
+ "module": "../_esm/test/index.js",
5
+ "main": "../_cjs/test/index.js"
6
+ }
@@ -0,0 +1,6 @@
1
+ {
2
+ "type": "module",
3
+ "types": "../_types/utils/index.d.ts",
4
+ "module": "../_esm/utils/index.js",
5
+ "main": "../_cjs/utils/index.js"
6
+ }
@@ -1,41 +1,46 @@
1
- export { addChain, type AddChainParameters } from './actions/wallet/addChain.js'
1
+ // TODO(v2): Remove this entrypoint. Favor importing from actions entrypoint (`viem/actions`).
2
+
3
+ export {
4
+ addChain,
5
+ type AddChainParameters,
6
+ } from '../actions/wallet/addChain.js'
2
7
  export {
3
8
  getAddresses,
4
9
  type GetAddressesReturnType,
5
- } from './actions/wallet/getAddresses.js'
10
+ } from '../actions/wallet/getAddresses.js'
6
11
  export {
7
12
  getPermissions,
8
13
  type GetPermissionsReturnType,
9
- } from './actions/wallet/getPermissions.js'
14
+ } from '../actions/wallet/getPermissions.js'
10
15
  export {
11
16
  requestAddresses,
12
17
  type RequestAddressesReturnType,
13
- } from './actions/wallet/requestAddresses.js'
18
+ } from '../actions/wallet/requestAddresses.js'
14
19
  export {
15
20
  requestPermissions,
16
21
  type RequestPermissionsReturnType,
17
- } from './actions/wallet/requestPermissions.js'
22
+ } from '../actions/wallet/requestPermissions.js'
18
23
  export {
19
24
  sendTransaction,
20
25
  type SendTransactionParameters,
21
26
  type SendTransactionReturnType,
22
- } from './actions/wallet/sendTransaction.js'
27
+ } from '../actions/wallet/sendTransaction.js'
23
28
  export {
24
29
  signMessage,
25
30
  type SignMessageParameters,
26
31
  type SignMessageReturnType,
27
- } from './actions/wallet/signMessage.js'
32
+ } from '../actions/wallet/signMessage.js'
28
33
  export {
29
34
  signTypedData,
30
35
  type SignTypedDataParameters,
31
36
  type SignTypedDataReturnType,
32
- } from './actions/wallet/signTypedData.js'
37
+ } from '../actions/wallet/signTypedData.js'
33
38
  export {
34
39
  switchChain,
35
40
  type SwitchChainParameters,
36
- } from './actions/wallet/switchChain.js'
41
+ } from '../actions/wallet/switchChain.js'
37
42
  export {
38
43
  watchAsset,
39
44
  type WatchAssetParameters,
40
45
  type WatchAssetReturnType,
41
- } from './actions/wallet/watchAsset.js'
46
+ } from '../actions/wallet/watchAsset.js'
@@ -0,0 +1,6 @@
1
+ {
2
+ "type": "module",
3
+ "types": "../_types/wallet/index.d.ts",
4
+ "module": "../_esm/wallet/index.js",
5
+ "main": "../_cjs/wallet/index.js"
6
+ }
@@ -0,0 +1,6 @@
1
+ {
2
+ "type": "module",
3
+ "types": "../_types/window/index.d.ts",
4
+ "module": "../_esm/window/index.js",
5
+ "main": "../_cjs/window/index.js"
6
+ }
@@ -0,0 +1 @@
1
+ import '../types/window.js'
package/CHANGELOG.md DELETED
@@ -1,9 +0,0 @@
1
- # viem
2
-
3
- ## 1.10.8
4
-
5
- ### Patch Changes
6
-
7
- - [`fa2d8794`](https://github.com/wagmi-dev/viem/commit/fa2d87942f792ee3b87c9ac291c2c82f8c2fc313) Thanks [@jxom](https://github.com/jxom)! - Fixed an issue where `waitForTransactionReceipt` would throw an error if `receipt.blockNumber` was undefined.
8
-
9
- - [#1194](https://github.com/wagmi-dev/viem/pull/1194) [`347b1f40`](https://github.com/wagmi-dev/viem/commit/347b1f40702c50745e1f0cc493d52eaee6f405eb) Thanks [@jxom](https://github.com/jxom)! - Fixed `baseFeeMultiplier` calculation.
package/_cjs/abi.js.map DELETED
@@ -1 +0,0 @@
1
- {"version":3,"file":"abi.js","sourceRoot":"","sources":["../abi.ts"],"names":[],"mappings":";;;AAAA,6EAG2C;AADzC,6HAAA,mBAAmB,OAAA;AAErB,6EAG2C;AADzC,6HAAA,mBAAmB,OAAA;AAErB,2DAGkC;AADhC,2GAAA,UAAU,OAAA;AAEZ,mCASgB;AAJd,mGAAA,QAAQ,OAAA;AACR,uGAAA,YAAY,OAAA;AACZ,4GAAA,iBAAiB,OAAA;AACjB,6GAAA,kBAAkB,OAAA;AAEpB,+DAA0D;AAAjD,+GAAA,YAAY,OAAA"}
@@ -1 +0,0 @@
1
- {"version":3,"file":"utils.js","sourceRoot":"","sources":["../../chains/utils.ts"],"names":[],"mappings":";;;AAAA,sDAAqD;AAA5C,+GAAA,cAAc,OAAA;AACvB,wDAG8B;AAF5B,0HAAA,wBAAwB,OAAA;AACxB,iHAAA,eAAe,OAAA;AAEjB,gDAAwD;AAA/C,kHAAA,oBAAoB,OAAA;AAyB7B,0DAA6D;AAApD,mHAAA,kBAAkB,OAAA"}