diff --git a/.changeset/pre.json b/.changeset/pre.json index 5184e96fad..fca5bda923 100644 --- a/.changeset/pre.json +++ b/.changeset/pre.json @@ -31,15 +31,28 @@ "@latticexyz/world": "1.42.0" }, "changesets": [ + "afraid-hotels-bathe", + "big-goats-prove", + "brave-rings-tickle", + "dirty-items-retire", "eighty-tigers-argue", "fast-ears-hug", + "fifty-squids-eat", + "giant-masks-carry", + "great-cooks-dream", "itchy-kids-relax", + "itchy-shoes-appear", + "large-hats-walk", "many-phones-study", + "mean-pans-study", + "metal-cats-double", "modern-bikes-build", "nasty-waves-divide", + "nice-moose-love", "nice-pandas-knock", "olive-parrots-move", "perfect-mangos-cry", + "pink-horses-deny", "quick-numbers-flash", "rare-planes-draw", "selfish-cycles-retire", @@ -49,6 +62,9 @@ "strange-candles-shout", "strange-ducks-float", "thin-buses-reply", - "tricky-frogs-beam" + "tricky-frogs-beam", + "tricky-olives-stare", + "weak-mails-cross", + "witty-jokes-serve" ] } diff --git a/CHANGELOG.md b/CHANGELOG.md index 3c8db7e3b2..4de0cb49d3 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -1,3 +1,71 @@ +# Version 2.0.0-next.1 + +## Major changes + +1. **[chore: fix changeset type (#1220)](https://github.com/latticexyz/mud/commit/2f6cfef91daacf09db82a4b7c69cff3af583b8f6)** (@latticexyz/store-sync) + +Adds store indexer service package with utils to query the indexer service. + +You can run the indexer locally by checking out the MUD monorepo, installing/building everything, and running `pnpm start:local` from `packages/store-indexer`. + +To query the indexer in the client, you can create a tRPC client with a URL pointing to the indexer service and call the available tRPC methods: + +```ts +import { createIndexerClient } from "@latticexyz/store-sync/trpc-indexer"; + +const indexer = createIndexerClient({ url: indexerUrl }); +const result = await indexer.findAll.query({ + chainId: publicClient.chain.id, + address, +}); +``` + +If you're using `syncToRecs`, you can just pass in the `indexerUrl` option as a shortcut to the above: + +```ts +import { syncToRecs } from "@latticexyz/store-sync/recs"; + +syncToRecs({ + ... + indexerUrl: "https://your.indexer.service", +}); +``` + +1. **[feat(common): replace TableId with tableIdToHex/hexToTableId (#1258)](https://github.com/latticexyz/mud/commit/6c6733256f91cddb0e913217cbd8e02e6bc484c7)** (@latticexyz/common, @latticexyz/dev-tools, @latticexyz/network, @latticexyz/std-client, @latticexyz/store-sync) + +Add `tableIdToHex` and `hexToTableId` pure functions and move/deprecate `TableId`. + +## Minor changes + +1. **[feat(store-indexer,store-sync): make chain optional, configure indexer with RPC (#1234)](https://github.com/latticexyz/mud/commit/131c63e539a8e9947835dcc323c8b37562aed9ca)** (@latticexyz/store-sync) + +- Accept a plain viem `PublicClient` (instead of requiring a `Chain` to be set) in `store-sync` and `store-indexer` functions. These functions now fetch chain ID using `publicClient.getChainId()` when no `publicClient.chain.id` is present. +- Allow configuring `store-indexer` with a set of RPC URLs (`RPC_HTTP_URL` and `RPC_WS_URL`) instead of `CHAIN_ID`. + +## Patch changes + +1. **[fix(cli): explicit import of world as type (#1206)](https://github.com/latticexyz/mud/commit/e259ef79f4d9026353176d0f74628cae50c2f69b)** (@latticexyz/std-client) + +Generated `contractComponents` now properly import `World` as type + +1. **[feat(cli,recs,std-client): update RECS components with v2 key/value schemas (#1195)](https://github.com/latticexyz/mud/commit/afdba793fd84abf17eef5ef59dd56fabe353c8bd)** (@latticexyz/recs, @latticexyz/std-client) + +Update RECS components with v2 key/value schemas. This helps with encoding/decoding composite keys and strong types for keys/values. + +This may break if you were previously dependent on `component.id`, `component.metadata.componentId`, or `component.metadata.tableId`: + +- `component.id` is now the on-chain `bytes32` hex representation of the table ID +- `component.metadata.componentName` is the table name (e.g. `Position`) +- `component.metadata.tableName` is the namespaced table name (e.g. `myworld:Position`) +- `component.metadata.keySchema` is an object with key names and their corresponding ABI types +- `component.metadata.valueSchema` is an object with field names and their corresponding ABI types + +1. **[refactor(store): update tightcoder codegen, optimize TightCoder library (#1210)](https://github.com/latticexyz/mud/commit/cc2c8da000c32c02a82a1a0fd17075d11eac56c3)** (@latticexyz/store, @latticexyz/world) + +- Refactor tightcoder to use typescript functions instead of ejs +- Optimize `TightCoder` library +- Add `isLeftAligned` and `getLeftPaddingBits` common codegen helpers + # Version 2.0.0-next.0 ## Minor changes diff --git a/packages/block-logs-stream/CHANGELOG.md b/packages/block-logs-stream/CHANGELOG.md index 170ff2344a..31347fe217 100644 --- a/packages/block-logs-stream/CHANGELOG.md +++ b/packages/block-logs-stream/CHANGELOG.md @@ -1,5 +1,14 @@ # @latticexyz/block-logs-stream +## 2.0.0-next.1 + +### Patch Changes + +- Updated dependencies [[`3fb9ce28`](https://github.com/latticexyz/mud/commit/3fb9ce2839271a0dcfe97f86394195f7a6f70f50), [`b02f9d0e`](https://github.com/latticexyz/mud/commit/b02f9d0e43089e5f9b46d817ea2032ce0a1b0b07), [`6c673325`](https://github.com/latticexyz/mud/commit/6c6733256f91cddb0e913217cbd8e02e6bc484c7), [`cc2c8da0`](https://github.com/latticexyz/mud/commit/cc2c8da000c32c02a82a1a0fd17075d11eac56c3)]: + - @latticexyz/common@2.0.0-next.1 + - @latticexyz/schema-type@2.0.0-next.1 + - @latticexyz/config@2.0.0-next.1 + ## 2.0.0-next.0 ### Minor Changes diff --git a/packages/block-logs-stream/package.json b/packages/block-logs-stream/package.json index c65a046ac3..a1f055f07e 100644 --- a/packages/block-logs-stream/package.json +++ b/packages/block-logs-stream/package.json @@ -1,6 +1,6 @@ { "name": "@latticexyz/block-logs-stream", - "version": "2.0.0-next.0", + "version": "2.0.0-next.1", "description": "Create a stream of EVM block logs for events", "repository": { "type": "git", diff --git a/packages/cli/CHANGELOG.md b/packages/cli/CHANGELOG.md index 8033dbe93a..5cbf07e47e 100644 --- a/packages/cli/CHANGELOG.md +++ b/packages/cli/CHANGELOG.md @@ -1,5 +1,37 @@ # Change Log +## 2.0.0-next.1 + +### Patch Changes + +- [#1178](https://github.com/latticexyz/mud/pull/1178) [`168a4cb4`](https://github.com/latticexyz/mud/commit/168a4cb43ce4f7bfbdb7b1b9d4c305b912a0d3f2) Thanks [@TheGreatAxios](https://github.com/TheGreatAxios)! - Add support for legacy transactions in deploy script by falling back to `gasPrice` if `lastBaseFeePerGas` is not available + +- [#1206](https://github.com/latticexyz/mud/pull/1206) [`e259ef79`](https://github.com/latticexyz/mud/commit/e259ef79f4d9026353176d0f74628cae50c2f69b) Thanks [@holic](https://github.com/holic)! - Generated `contractComponents` now properly import `World` as type + +- [`6c673325`](https://github.com/latticexyz/mud/commit/6c6733256f91cddb0e913217cbd8e02e6bc484c7) Thanks [@holic](https://github.com/holic)! - Add `tableIdToHex` and `hexToTableId` pure functions and move/deprecate `TableId`. + +- [#1195](https://github.com/latticexyz/mud/pull/1195) [`afdba793`](https://github.com/latticexyz/mud/commit/afdba793fd84abf17eef5ef59dd56fabe353c8bd) Thanks [@holic](https://github.com/holic)! - Update RECS components with v2 key/value schemas. This helps with encoding/decoding composite keys and strong types for keys/values. + + This may break if you were previously dependent on `component.id`, `component.metadata.componentId`, or `component.metadata.tableId`: + + - `component.id` is now the on-chain `bytes32` hex representation of the table ID + - `component.metadata.componentName` is the table name (e.g. `Position`) + - `component.metadata.tableName` is the namespaced table name (e.g. `myworld:Position`) + - `component.metadata.keySchema` is an object with key names and their corresponding ABI types + - `component.metadata.valueSchema` is an object with field names and their corresponding ABI types + +- Updated dependencies [[`3236f799`](https://github.com/latticexyz/mud/commit/3236f799e501be227da6e42e7b41a4928750115c), [`c963b46c`](https://github.com/latticexyz/mud/commit/c963b46c7eaceebc652930936643365b8c48a021), [`3fb9ce28`](https://github.com/latticexyz/mud/commit/3fb9ce2839271a0dcfe97f86394195f7a6f70f50), [`5c965a91`](https://github.com/latticexyz/mud/commit/5c965a919355bf98d7ea69463890fe605bcde206), [`b02f9d0e`](https://github.com/latticexyz/mud/commit/b02f9d0e43089e5f9b46d817ea2032ce0a1b0b07), [`6c673325`](https://github.com/latticexyz/mud/commit/6c6733256f91cddb0e913217cbd8e02e6bc484c7), [`cc2c8da0`](https://github.com/latticexyz/mud/commit/cc2c8da000c32c02a82a1a0fd17075d11eac56c3)]: + - @latticexyz/services@2.0.0-next.1 + - @latticexyz/store@2.0.0-next.1 + - @latticexyz/common@2.0.0-next.1 + - @latticexyz/schema-type@2.0.0-next.1 + - @latticexyz/world@2.0.0-next.1 + - @latticexyz/config@2.0.0-next.1 + - @latticexyz/utils@2.0.0-next.1 + - @latticexyz/gas-report@2.0.0-next.1 + - @latticexyz/solecs@2.0.0-next.1 + - @latticexyz/std-contracts@2.0.0-next.1 + ## 2.0.0-next.0 ### Minor Changes diff --git a/packages/cli/package.json b/packages/cli/package.json index b7c959f0a1..9fea153713 100644 --- a/packages/cli/package.json +++ b/packages/cli/package.json @@ -1,6 +1,6 @@ { "name": "@latticexyz/cli", - "version": "2.0.0-next.0", + "version": "2.0.0-next.1", "description": "Command line interface for mud", "repository": { "type": "git", diff --git a/packages/common/CHANGELOG.md b/packages/common/CHANGELOG.md index 8b0f96e90f..a0a110d837 100644 --- a/packages/common/CHANGELOG.md +++ b/packages/common/CHANGELOG.md @@ -1,5 +1,41 @@ # Change Log +## 2.0.0-next.1 + +### Major Changes + +- [`6c673325`](https://github.com/latticexyz/mud/commit/6c6733256f91cddb0e913217cbd8e02e6bc484c7) Thanks [@holic](https://github.com/holic)! - Add `tableIdToHex` and `hexToTableId` pure functions and move/deprecate `TableId`. + +### Minor Changes + +- [#1245](https://github.com/latticexyz/mud/pull/1245) [`3fb9ce28`](https://github.com/latticexyz/mud/commit/3fb9ce2839271a0dcfe97f86394195f7a6f70f50) Thanks [@holic](https://github.com/holic)! - Add utils for using viem with MUD + + - `mudFoundry` chain with a transaction request formatter that temporarily removes max fees to work better with anvil `--base-fee 0` + - `createBurnerAccount` that also temporarily removes max fees during transaction signing to work better with anvil `--base-fee 0` + - `mudTransportObserver` that will soon let MUD Dev Tools observe transactions + + You can use them like: + + ```ts + import { createBurnerAccount, mudTransportObserver } from "@latticexyz/common"; + import { mudFoundry } from "@latticexyz/common/chains"; + + createWalletClient({ + account: createBurnerAccount(privateKey), + chain: mudFoundry, + transport: mudTransportObserver(http()), + pollingInterval: 1000, + }); + ``` + +### Patch Changes + +- [#1210](https://github.com/latticexyz/mud/pull/1210) [`cc2c8da0`](https://github.com/latticexyz/mud/commit/cc2c8da000c32c02a82a1a0fd17075d11eac56c3) Thanks [@dk1a](https://github.com/dk1a)! - - Refactor tightcoder to use typescript functions instead of ejs + - Optimize `TightCoder` library + - Add `isLeftAligned` and `getLeftPaddingBits` common codegen helpers +- Updated dependencies [[`b02f9d0e`](https://github.com/latticexyz/mud/commit/b02f9d0e43089e5f9b46d817ea2032ce0a1b0b07)]: + - @latticexyz/schema-type@2.0.0-next.1 + ## 2.0.0-next.0 ### Minor Changes diff --git a/packages/common/package.json b/packages/common/package.json index 244e1f6c36..62561f60a5 100644 --- a/packages/common/package.json +++ b/packages/common/package.json @@ -1,6 +1,6 @@ { "name": "@latticexyz/common", - "version": "2.0.0-next.0", + "version": "2.0.0-next.1", "description": "Common low level logic shared between packages", "repository": { "type": "git", diff --git a/packages/config/CHANGELOG.md b/packages/config/CHANGELOG.md index 600de540f4..90bb6b54f8 100644 --- a/packages/config/CHANGELOG.md +++ b/packages/config/CHANGELOG.md @@ -1,5 +1,13 @@ # Change Log +## 2.0.0-next.1 + +### Patch Changes + +- Updated dependencies [[`3fb9ce28`](https://github.com/latticexyz/mud/commit/3fb9ce2839271a0dcfe97f86394195f7a6f70f50), [`b02f9d0e`](https://github.com/latticexyz/mud/commit/b02f9d0e43089e5f9b46d817ea2032ce0a1b0b07), [`6c673325`](https://github.com/latticexyz/mud/commit/6c6733256f91cddb0e913217cbd8e02e6bc484c7), [`cc2c8da0`](https://github.com/latticexyz/mud/commit/cc2c8da000c32c02a82a1a0fd17075d11eac56c3)]: + - @latticexyz/common@2.0.0-next.1 + - @latticexyz/schema-type@2.0.0-next.1 + ## 2.0.0-next.0 ### Patch Changes diff --git a/packages/config/package.json b/packages/config/package.json index 97167c71ef..25c16ecf4d 100644 --- a/packages/config/package.json +++ b/packages/config/package.json @@ -1,6 +1,6 @@ { "name": "@latticexyz/config", - "version": "2.0.0-next.0", + "version": "2.0.0-next.1", "description": "Config for Store and World", "repository": { "type": "git", diff --git a/packages/create-mud/CHANGELOG.md b/packages/create-mud/CHANGELOG.md index 6da28de26b..64d17a6edc 100644 --- a/packages/create-mud/CHANGELOG.md +++ b/packages/create-mud/CHANGELOG.md @@ -1,5 +1,7 @@ # Change Log +## 2.0.0-next.1 + ## 2.0.0-next.0 ### Patch Changes diff --git a/packages/create-mud/package.json b/packages/create-mud/package.json index 59bb091628..df39dea0d5 100644 --- a/packages/create-mud/package.json +++ b/packages/create-mud/package.json @@ -1,6 +1,6 @@ { "name": "create-mud", - "version": "2.0.0-next.0", + "version": "2.0.0-next.1", "description": "Create a new MUD project", "license": "MIT", "author": "Lattice ", diff --git a/packages/dev-tools/CHANGELOG.md b/packages/dev-tools/CHANGELOG.md index 6e8ab1fb50..b16be38008 100644 --- a/packages/dev-tools/CHANGELOG.md +++ b/packages/dev-tools/CHANGELOG.md @@ -1,5 +1,19 @@ # @latticexyz/dev-tools +## 2.0.0-next.1 + +### Patch Changes + +- [`6c673325`](https://github.com/latticexyz/mud/commit/6c6733256f91cddb0e913217cbd8e02e6bc484c7) Thanks [@holic](https://github.com/holic)! - Add `tableIdToHex` and `hexToTableId` pure functions and move/deprecate `TableId`. + +- Updated dependencies [[`3fb9ce28`](https://github.com/latticexyz/mud/commit/3fb9ce2839271a0dcfe97f86394195f7a6f70f50), [`e259ef79`](https://github.com/latticexyz/mud/commit/e259ef79f4d9026353176d0f74628cae50c2f69b), [`6c673325`](https://github.com/latticexyz/mud/commit/6c6733256f91cddb0e913217cbd8e02e6bc484c7), [`afdba793`](https://github.com/latticexyz/mud/commit/afdba793fd84abf17eef5ef59dd56fabe353c8bd), [`cc2c8da0`](https://github.com/latticexyz/mud/commit/cc2c8da000c32c02a82a1a0fd17075d11eac56c3)]: + - @latticexyz/common@2.0.0-next.1 + - @latticexyz/std-client@2.0.0-next.1 + - @latticexyz/network@2.0.0-next.1 + - @latticexyz/world@2.0.0-next.1 + - @latticexyz/react@2.0.0-next.1 + - @latticexyz/utils@2.0.0-next.1 + ## 2.0.0-next.0 ### Patch Changes diff --git a/packages/dev-tools/package.json b/packages/dev-tools/package.json index 1e8bc30740..9a7f1d5268 100644 --- a/packages/dev-tools/package.json +++ b/packages/dev-tools/package.json @@ -1,6 +1,6 @@ { "name": "@latticexyz/dev-tools", - "version": "2.0.0-next.0", + "version": "2.0.0-next.1", "description": "MUD developer tools", "repository": { "type": "git", @@ -49,10 +49,10 @@ "vitest": "0.31.4" }, "peerDependencies": { - "@latticexyz/network": "2.0.0-next.0", - "@latticexyz/std-client": "2.0.0-next.0", - "@latticexyz/utils": "2.0.0-next.0", - "@latticexyz/world": "2.0.0-next.0" + "@latticexyz/network": "2.0.0-next.1", + "@latticexyz/std-client": "2.0.0-next.1", + "@latticexyz/utils": "2.0.0-next.1", + "@latticexyz/world": "2.0.0-next.1" }, "publishConfig": { "access": "public" diff --git a/packages/ecs-browser/CHANGELOG.md b/packages/ecs-browser/CHANGELOG.md index 4ba8554b59..ac740daab1 100644 --- a/packages/ecs-browser/CHANGELOG.md +++ b/packages/ecs-browser/CHANGELOG.md @@ -1,5 +1,14 @@ # Change Log +## 2.0.0-next.1 + +### Patch Changes + +- Updated dependencies [[`e259ef79`](https://github.com/latticexyz/mud/commit/e259ef79f4d9026353176d0f74628cae50c2f69b), [`6c673325`](https://github.com/latticexyz/mud/commit/6c6733256f91cddb0e913217cbd8e02e6bc484c7), [`afdba793`](https://github.com/latticexyz/mud/commit/afdba793fd84abf17eef5ef59dd56fabe353c8bd)]: + - @latticexyz/std-client@2.0.0-next.1 + - @latticexyz/recs@2.0.0-next.1 + - @latticexyz/utils@2.0.0-next.1 + ## 2.0.0-next.0 ### Patch Changes diff --git a/packages/ecs-browser/package.json b/packages/ecs-browser/package.json index 5b0d506419..1cb7b53a42 100644 --- a/packages/ecs-browser/package.json +++ b/packages/ecs-browser/package.json @@ -1,6 +1,6 @@ { "name": "@latticexyz/ecs-browser", - "version": "2.0.0-next.0", + "version": "2.0.0-next.1", "description": "Component Browser for RECS", "repository": { "type": "git", diff --git a/packages/gas-report/CHANGELOG.md b/packages/gas-report/CHANGELOG.md index 3142a43f4a..552b0de501 100644 --- a/packages/gas-report/CHANGELOG.md +++ b/packages/gas-report/CHANGELOG.md @@ -1,5 +1,7 @@ # Change Log +## 2.0.0-next.1 + ## 2.0.0-next.0 ### Minor Changes diff --git a/packages/gas-report/package.json b/packages/gas-report/package.json index 91298ffa0c..afe9c8d17d 100644 --- a/packages/gas-report/package.json +++ b/packages/gas-report/package.json @@ -1,6 +1,6 @@ { "name": "@latticexyz/gas-report", - "version": "2.0.0-next.0", + "version": "2.0.0-next.1", "description": "Gas reporter for specific lines within forge tests", "repository": { "type": "git", diff --git a/packages/network/CHANGELOG.md b/packages/network/CHANGELOG.md index 27254774ef..555e77aa09 100644 --- a/packages/network/CHANGELOG.md +++ b/packages/network/CHANGELOG.md @@ -1,5 +1,21 @@ # Change Log +## 2.0.0-next.1 + +### Patch Changes + +- [`6c673325`](https://github.com/latticexyz/mud/commit/6c6733256f91cddb0e913217cbd8e02e6bc484c7) Thanks [@holic](https://github.com/holic)! - Add `tableIdToHex` and `hexToTableId` pure functions and move/deprecate `TableId`. + +- Updated dependencies [[`3236f799`](https://github.com/latticexyz/mud/commit/3236f799e501be227da6e42e7b41a4928750115c), [`c963b46c`](https://github.com/latticexyz/mud/commit/c963b46c7eaceebc652930936643365b8c48a021), [`3fb9ce28`](https://github.com/latticexyz/mud/commit/3fb9ce2839271a0dcfe97f86394195f7a6f70f50), [`5c965a91`](https://github.com/latticexyz/mud/commit/5c965a919355bf98d7ea69463890fe605bcde206), [`b02f9d0e`](https://github.com/latticexyz/mud/commit/b02f9d0e43089e5f9b46d817ea2032ce0a1b0b07), [`6c673325`](https://github.com/latticexyz/mud/commit/6c6733256f91cddb0e913217cbd8e02e6bc484c7), [`afdba793`](https://github.com/latticexyz/mud/commit/afdba793fd84abf17eef5ef59dd56fabe353c8bd), [`cc2c8da0`](https://github.com/latticexyz/mud/commit/cc2c8da000c32c02a82a1a0fd17075d11eac56c3)]: + - @latticexyz/services@2.0.0-next.1 + - @latticexyz/store@2.0.0-next.1 + - @latticexyz/common@2.0.0-next.1 + - @latticexyz/schema-type@2.0.0-next.1 + - @latticexyz/recs@2.0.0-next.1 + - @latticexyz/world@2.0.0-next.1 + - @latticexyz/utils@2.0.0-next.1 + - @latticexyz/solecs@2.0.0-next.1 + ## 2.0.0-next.0 ### Patch Changes diff --git a/packages/network/package.json b/packages/network/package.json index 2d47dc50f7..0c773301a2 100644 --- a/packages/network/package.json +++ b/packages/network/package.json @@ -1,6 +1,6 @@ { "name": "@latticexyz/network", - "version": "2.0.0-next.0", + "version": "2.0.0-next.1", "repository": { "type": "git", "url": "https://github.com/latticexyz/mud.git", diff --git a/packages/noise/CHANGELOG.md b/packages/noise/CHANGELOG.md index 909fd2841d..885f03e4c1 100644 --- a/packages/noise/CHANGELOG.md +++ b/packages/noise/CHANGELOG.md @@ -1,5 +1,7 @@ # Change Log +## 2.0.0-next.1 + ## 2.0.0-next.0 ### Patch Changes diff --git a/packages/noise/package.json b/packages/noise/package.json index 7a03c172b7..3f06771e55 100644 --- a/packages/noise/package.json +++ b/packages/noise/package.json @@ -1,6 +1,6 @@ { "name": "@latticexyz/noise", - "version": "2.0.0-next.0", + "version": "2.0.0-next.1", "license": "MIT", "type": "module", "exports": { diff --git a/packages/phaserx/CHANGELOG.md b/packages/phaserx/CHANGELOG.md index fc7e820464..3008ff8e78 100644 --- a/packages/phaserx/CHANGELOG.md +++ b/packages/phaserx/CHANGELOG.md @@ -1,5 +1,12 @@ # Change Log +## 2.0.0-next.1 + +### Patch Changes + +- Updated dependencies []: + - @latticexyz/utils@2.0.0-next.1 + ## 2.0.0-next.0 ### Patch Changes diff --git a/packages/phaserx/package.json b/packages/phaserx/package.json index 2c46aecc02..4af5e4914b 100644 --- a/packages/phaserx/package.json +++ b/packages/phaserx/package.json @@ -1,6 +1,6 @@ { "name": "@latticexyz/phaserx", - "version": "2.0.0-next.0", + "version": "2.0.0-next.1", "repository": { "type": "git", "url": "https://github.com/latticexyz/mud.git", diff --git a/packages/protocol-parser/CHANGELOG.md b/packages/protocol-parser/CHANGELOG.md index 86b3d6f569..cd1369554b 100644 --- a/packages/protocol-parser/CHANGELOG.md +++ b/packages/protocol-parser/CHANGELOG.md @@ -1,5 +1,13 @@ # @latticexyz/protocol-parser +## 2.0.0-next.1 + +### Patch Changes + +- Updated dependencies [[`3fb9ce28`](https://github.com/latticexyz/mud/commit/3fb9ce2839271a0dcfe97f86394195f7a6f70f50), [`b02f9d0e`](https://github.com/latticexyz/mud/commit/b02f9d0e43089e5f9b46d817ea2032ce0a1b0b07), [`6c673325`](https://github.com/latticexyz/mud/commit/6c6733256f91cddb0e913217cbd8e02e6bc484c7), [`cc2c8da0`](https://github.com/latticexyz/mud/commit/cc2c8da000c32c02a82a1a0fd17075d11eac56c3)]: + - @latticexyz/common@2.0.0-next.1 + - @latticexyz/schema-type@2.0.0-next.1 + ## 2.0.0-next.0 ### Minor Changes diff --git a/packages/protocol-parser/package.json b/packages/protocol-parser/package.json index e5272606d9..c340f7660c 100644 --- a/packages/protocol-parser/package.json +++ b/packages/protocol-parser/package.json @@ -1,6 +1,6 @@ { "name": "@latticexyz/protocol-parser", - "version": "2.0.0-next.0", + "version": "2.0.0-next.1", "description": "Parser utilities for the MUD protocol", "repository": { "type": "git", diff --git a/packages/react/CHANGELOG.md b/packages/react/CHANGELOG.md index 893e61296b..ada862f6b7 100644 --- a/packages/react/CHANGELOG.md +++ b/packages/react/CHANGELOG.md @@ -1,5 +1,14 @@ # Change Log +## 2.0.0-next.1 + +### Patch Changes + +- Updated dependencies [[`c963b46c`](https://github.com/latticexyz/mud/commit/c963b46c7eaceebc652930936643365b8c48a021), [`5c965a91`](https://github.com/latticexyz/mud/commit/5c965a919355bf98d7ea69463890fe605bcde206), [`afdba793`](https://github.com/latticexyz/mud/commit/afdba793fd84abf17eef5ef59dd56fabe353c8bd), [`cc2c8da0`](https://github.com/latticexyz/mud/commit/cc2c8da000c32c02a82a1a0fd17075d11eac56c3)]: + - @latticexyz/store@2.0.0-next.1 + - @latticexyz/recs@2.0.0-next.1 + - @latticexyz/store-cache@2.0.0-next.1 + ## 2.0.0-next.0 ### Patch Changes diff --git a/packages/react/package.json b/packages/react/package.json index 72d54a04dd..f3ba944dbc 100644 --- a/packages/react/package.json +++ b/packages/react/package.json @@ -1,6 +1,6 @@ { "name": "@latticexyz/react", - "version": "2.0.0-next.0", + "version": "2.0.0-next.1", "description": "React tools for MUD client.", "repository": { "type": "git", diff --git a/packages/recs/CHANGELOG.md b/packages/recs/CHANGELOG.md index d8391e781d..a892df238c 100644 --- a/packages/recs/CHANGELOG.md +++ b/packages/recs/CHANGELOG.md @@ -1,5 +1,23 @@ # Change Log +## 2.0.0-next.1 + +### Patch Changes + +- [#1195](https://github.com/latticexyz/mud/pull/1195) [`afdba793`](https://github.com/latticexyz/mud/commit/afdba793fd84abf17eef5ef59dd56fabe353c8bd) Thanks [@holic](https://github.com/holic)! - Update RECS components with v2 key/value schemas. This helps with encoding/decoding composite keys and strong types for keys/values. + + This may break if you were previously dependent on `component.id`, `component.metadata.componentId`, or `component.metadata.tableId`: + + - `component.id` is now the on-chain `bytes32` hex representation of the table ID + - `component.metadata.componentName` is the table name (e.g. `Position`) + - `component.metadata.tableName` is the namespaced table name (e.g. `myworld:Position`) + - `component.metadata.keySchema` is an object with key names and their corresponding ABI types + - `component.metadata.valueSchema` is an object with field names and their corresponding ABI types + +- Updated dependencies [[`b02f9d0e`](https://github.com/latticexyz/mud/commit/b02f9d0e43089e5f9b46d817ea2032ce0a1b0b07)]: + - @latticexyz/schema-type@2.0.0-next.1 + - @latticexyz/utils@2.0.0-next.1 + ## 2.0.0-next.0 ### Patch Changes diff --git a/packages/recs/package.json b/packages/recs/package.json index 2a83e49696..f1016cfdce 100644 --- a/packages/recs/package.json +++ b/packages/recs/package.json @@ -1,6 +1,6 @@ { "name": "@latticexyz/recs", - "version": "2.0.0-next.0", + "version": "2.0.0-next.1", "repository": { "type": "git", "url": "https://github.com/latticexyz/mud.git", diff --git a/packages/schema-type/CHANGELOG.md b/packages/schema-type/CHANGELOG.md index 87bd04d59c..07f3bdee33 100644 --- a/packages/schema-type/CHANGELOG.md +++ b/packages/schema-type/CHANGELOG.md @@ -1,5 +1,11 @@ # Change Log +## 2.0.0-next.1 + +### Minor Changes + +- [#1196](https://github.com/latticexyz/mud/pull/1196) [`b02f9d0e`](https://github.com/latticexyz/mud/commit/b02f9d0e43089e5f9b46d817ea2032ce0a1b0b07) Thanks [@holic](https://github.com/holic)! - add type narrowing `isStaticAbiType` + ## 2.0.0-next.0 ### Patch Changes diff --git a/packages/schema-type/package.json b/packages/schema-type/package.json index d22d473607..8359220b20 100644 --- a/packages/schema-type/package.json +++ b/packages/schema-type/package.json @@ -1,6 +1,6 @@ { "name": "@latticexyz/schema-type", - "version": "2.0.0-next.0", + "version": "2.0.0-next.1", "description": "SchemaType enum for various languages", "repository": { "type": "git", diff --git a/packages/services/CHANGELOG.md b/packages/services/CHANGELOG.md index af1b1d6420..5e1cb9198b 100644 --- a/packages/services/CHANGELOG.md +++ b/packages/services/CHANGELOG.md @@ -1,5 +1,11 @@ # Change Log +## 2.0.0-next.1 + +### Patch Changes + +- [#1116](https://github.com/latticexyz/mud/pull/1116) [`3236f799`](https://github.com/latticexyz/mud/commit/3236f799e501be227da6e42e7b41a4928750115c) Thanks [@authcall](https://github.com/authcall)! - protocol-parser in Go + ## 2.0.0-next.0 ### Patch Changes diff --git a/packages/services/package.json b/packages/services/package.json index f6f1589f34..68172e8f6f 100644 --- a/packages/services/package.json +++ b/packages/services/package.json @@ -1,6 +1,6 @@ { "name": "@latticexyz/services", - "version": "2.0.0-next.0", + "version": "2.0.0-next.1", "description": "MUD services for enhanced interactions with on-chain ECS state", "repository": { "type": "git", diff --git a/packages/solecs/CHANGELOG.md b/packages/solecs/CHANGELOG.md index 37b870fea7..302792aeb7 100644 --- a/packages/solecs/CHANGELOG.md +++ b/packages/solecs/CHANGELOG.md @@ -1,5 +1,7 @@ # Change Log +## 2.0.0-next.1 + ## 2.0.0-next.0 ### Patch Changes diff --git a/packages/solecs/package.json b/packages/solecs/package.json index 42a459096c..32b0ffd8e4 100644 --- a/packages/solecs/package.json +++ b/packages/solecs/package.json @@ -1,6 +1,6 @@ { "name": "@latticexyz/solecs", - "version": "2.0.0-next.0", + "version": "2.0.0-next.1", "description": "Solidity Entity Component System", "repository": { "type": "git", diff --git a/packages/solhint-config-mud/CHANGELOG.md b/packages/solhint-config-mud/CHANGELOG.md index da3ed97883..c804e256a5 100644 --- a/packages/solhint-config-mud/CHANGELOG.md +++ b/packages/solhint-config-mud/CHANGELOG.md @@ -1,5 +1,7 @@ # Change Log +## 2.0.0-next.1 + ## 2.0.0-next.0 All notable changes to this project will be documented in this file. diff --git a/packages/solhint-config-mud/package.json b/packages/solhint-config-mud/package.json index 950cb06b82..a2ee399c42 100644 --- a/packages/solhint-config-mud/package.json +++ b/packages/solhint-config-mud/package.json @@ -1,6 +1,6 @@ { "name": "solhint-config-mud", - "version": "2.0.0-next.0", + "version": "2.0.0-next.1", "repository": { "type": "git", "url": "https://github.com/latticexyz/mud.git", diff --git a/packages/solhint-plugin-mud/CHANGELOG.md b/packages/solhint-plugin-mud/CHANGELOG.md index da3ed97883..c804e256a5 100644 --- a/packages/solhint-plugin-mud/CHANGELOG.md +++ b/packages/solhint-plugin-mud/CHANGELOG.md @@ -1,5 +1,7 @@ # Change Log +## 2.0.0-next.1 + ## 2.0.0-next.0 All notable changes to this project will be documented in this file. diff --git a/packages/solhint-plugin-mud/package.json b/packages/solhint-plugin-mud/package.json index aad68cd4e7..909da43ef5 100644 --- a/packages/solhint-plugin-mud/package.json +++ b/packages/solhint-plugin-mud/package.json @@ -1,6 +1,6 @@ { "name": "solhint-plugin-mud", - "version": "2.0.0-next.0", + "version": "2.0.0-next.1", "repository": { "type": "git", "url": "https://github.com/latticexyz/mud.git", diff --git a/packages/std-client/CHANGELOG.md b/packages/std-client/CHANGELOG.md index 4c940d9b63..062c9db920 100644 --- a/packages/std-client/CHANGELOG.md +++ b/packages/std-client/CHANGELOG.md @@ -1,5 +1,35 @@ # Change Log +## 2.0.0-next.1 + +### Patch Changes + +- [#1206](https://github.com/latticexyz/mud/pull/1206) [`e259ef79`](https://github.com/latticexyz/mud/commit/e259ef79f4d9026353176d0f74628cae50c2f69b) Thanks [@holic](https://github.com/holic)! - Generated `contractComponents` now properly import `World` as type + +- [`6c673325`](https://github.com/latticexyz/mud/commit/6c6733256f91cddb0e913217cbd8e02e6bc484c7) Thanks [@holic](https://github.com/holic)! - Add `tableIdToHex` and `hexToTableId` pure functions and move/deprecate `TableId`. + +- [#1195](https://github.com/latticexyz/mud/pull/1195) [`afdba793`](https://github.com/latticexyz/mud/commit/afdba793fd84abf17eef5ef59dd56fabe353c8bd) Thanks [@holic](https://github.com/holic)! - Update RECS components with v2 key/value schemas. This helps with encoding/decoding composite keys and strong types for keys/values. + + This may break if you were previously dependent on `component.id`, `component.metadata.componentId`, or `component.metadata.tableId`: + + - `component.id` is now the on-chain `bytes32` hex representation of the table ID + - `component.metadata.componentName` is the table name (e.g. `Position`) + - `component.metadata.tableName` is the namespaced table name (e.g. `myworld:Position`) + - `component.metadata.keySchema` is an object with key names and their corresponding ABI types + - `component.metadata.valueSchema` is an object with field names and their corresponding ABI types + +- Updated dependencies [[`168a4cb4`](https://github.com/latticexyz/mud/commit/168a4cb43ce4f7bfbdb7b1b9d4c305b912a0d3f2), [`c963b46c`](https://github.com/latticexyz/mud/commit/c963b46c7eaceebc652930936643365b8c48a021), [`3fb9ce28`](https://github.com/latticexyz/mud/commit/3fb9ce2839271a0dcfe97f86394195f7a6f70f50), [`5c965a91`](https://github.com/latticexyz/mud/commit/5c965a919355bf98d7ea69463890fe605bcde206), [`e259ef79`](https://github.com/latticexyz/mud/commit/e259ef79f4d9026353176d0f74628cae50c2f69b), [`6c673325`](https://github.com/latticexyz/mud/commit/6c6733256f91cddb0e913217cbd8e02e6bc484c7), [`afdba793`](https://github.com/latticexyz/mud/commit/afdba793fd84abf17eef5ef59dd56fabe353c8bd), [`cc2c8da0`](https://github.com/latticexyz/mud/commit/cc2c8da000c32c02a82a1a0fd17075d11eac56c3)]: + - @latticexyz/cli@2.0.0-next.1 + - @latticexyz/store@2.0.0-next.1 + - @latticexyz/common@2.0.0-next.1 + - @latticexyz/network@2.0.0-next.1 + - @latticexyz/recs@2.0.0-next.1 + - @latticexyz/world@2.0.0-next.1 + - @latticexyz/store-cache@2.0.0-next.1 + - @latticexyz/config@2.0.0-next.1 + - @latticexyz/utils@2.0.0-next.1 + - @latticexyz/solecs@2.0.0-next.1 + ## 2.0.0-next.0 ### Patch Changes diff --git a/packages/std-client/package.json b/packages/std-client/package.json index 38ede79c5a..888c75f3bb 100644 --- a/packages/std-client/package.json +++ b/packages/std-client/package.json @@ -1,6 +1,6 @@ { "name": "@latticexyz/std-client", - "version": "2.0.0-next.0", + "version": "2.0.0-next.1", "description": "Standard library for MUD client.", "repository": { "type": "git", diff --git a/packages/std-contracts/CHANGELOG.md b/packages/std-contracts/CHANGELOG.md index 00b22b7f08..61e2c56abe 100644 --- a/packages/std-contracts/CHANGELOG.md +++ b/packages/std-contracts/CHANGELOG.md @@ -1,5 +1,7 @@ # Change Log +## 2.0.0-next.1 + ## 2.0.0-next.0 ### Minor Changes diff --git a/packages/std-contracts/package.json b/packages/std-contracts/package.json index 81727f613c..b70ccc72e7 100644 --- a/packages/std-contracts/package.json +++ b/packages/std-contracts/package.json @@ -1,6 +1,6 @@ { "name": "@latticexyz/std-contracts", - "version": "2.0.0-next.0", + "version": "2.0.0-next.1", "description": "MUD Contracts Standard Library", "repository": { "type": "git", diff --git a/packages/store-cache/CHANGELOG.md b/packages/store-cache/CHANGELOG.md index dedfd98bb8..32351fa20a 100644 --- a/packages/store-cache/CHANGELOG.md +++ b/packages/store-cache/CHANGELOG.md @@ -1,5 +1,15 @@ # Change Log +## 2.0.0-next.1 + +### Patch Changes + +- Updated dependencies [[`c963b46c`](https://github.com/latticexyz/mud/commit/c963b46c7eaceebc652930936643365b8c48a021), [`3fb9ce28`](https://github.com/latticexyz/mud/commit/3fb9ce2839271a0dcfe97f86394195f7a6f70f50), [`5c965a91`](https://github.com/latticexyz/mud/commit/5c965a919355bf98d7ea69463890fe605bcde206), [`b02f9d0e`](https://github.com/latticexyz/mud/commit/b02f9d0e43089e5f9b46d817ea2032ce0a1b0b07), [`6c673325`](https://github.com/latticexyz/mud/commit/6c6733256f91cddb0e913217cbd8e02e6bc484c7), [`cc2c8da0`](https://github.com/latticexyz/mud/commit/cc2c8da000c32c02a82a1a0fd17075d11eac56c3)]: + - @latticexyz/store@2.0.0-next.1 + - @latticexyz/common@2.0.0-next.1 + - @latticexyz/schema-type@2.0.0-next.1 + - @latticexyz/config@2.0.0-next.1 + ## 2.0.0-next.0 ### Patch Changes diff --git a/packages/store-cache/package.json b/packages/store-cache/package.json index 2031277211..013f9247f4 100644 --- a/packages/store-cache/package.json +++ b/packages/store-cache/package.json @@ -1,6 +1,6 @@ { "name": "@latticexyz/store-cache", - "version": "2.0.0-next.0", + "version": "2.0.0-next.1", "description": "Database to replicate Store contract state on a TypeScript client", "repository": { "type": "git", diff --git a/packages/store-indexer/CHANGELOG.md b/packages/store-indexer/CHANGELOG.md new file mode 100644 index 0000000000..4069eea114 --- /dev/null +++ b/packages/store-indexer/CHANGELOG.md @@ -0,0 +1,45 @@ +# @latticexyz/store-indexer + +## 2.0.0-next.1 + +### Major Changes + +- [#1198](https://github.com/latticexyz/mud/pull/1198) [`e86fbc12`](https://github.com/latticexyz/mud/commit/e86fbc1260f698c6a7b6a92c901fefd186c329ff) Thanks [@holic](https://github.com/holic)! - Adds store indexer service package with utils to query the indexer service. + + You can run the indexer locally by checking out the MUD monorepo, installing/building everything, and running `pnpm start:local` from `packages/store-indexer`. + + To query the indexer in the client, you can create a tRPC client with a URL pointing to the indexer service and call the available tRPC methods: + + ```ts + import { createIndexerClient } from "@latticexyz/store-sync/trpc-indexer"; + + const indexer = createIndexerClient({ url: indexerUrl }); + const result = await indexer.findAll.query({ + chainId: publicClient.chain.id, + address, + }); + ``` + + If you're using `syncToRecs`, you can just pass in the `indexerUrl` option as a shortcut to the above: + + ```ts + import { syncToRecs } from "@latticexyz/store-sync/recs"; + + syncToRecs({ + ... + indexerUrl: "https://your.indexer.service", + }); + ``` + +### Minor Changes + +- [#1234](https://github.com/latticexyz/mud/pull/1234) [`131c63e5`](https://github.com/latticexyz/mud/commit/131c63e539a8e9947835dcc323c8b37562aed9ca) Thanks [@holic](https://github.com/holic)! - - Accept a plain viem `PublicClient` (instead of requiring a `Chain` to be set) in `store-sync` and `store-indexer` functions. These functions now fetch chain ID using `publicClient.getChainId()` when no `publicClient.chain.id` is present. + - Allow configuring `store-indexer` with a set of RPC URLs (`RPC_HTTP_URL` and `RPC_WS_URL`) instead of `CHAIN_ID`. + +### Patch Changes + +- Updated dependencies [[`c963b46c`](https://github.com/latticexyz/mud/commit/c963b46c7eaceebc652930936643365b8c48a021), [`e86fbc12`](https://github.com/latticexyz/mud/commit/e86fbc1260f698c6a7b6a92c901fefd186c329ff), [`3fb9ce28`](https://github.com/latticexyz/mud/commit/3fb9ce2839271a0dcfe97f86394195f7a6f70f50), [`57a52608`](https://github.com/latticexyz/mud/commit/57a5260830401c9ad93196a895a50b0fc4a86183), [`9e5baf4f`](https://github.com/latticexyz/mud/commit/9e5baf4fff0c60615b8f2b4645fb11cb78cb0bd8), [`131c63e5`](https://github.com/latticexyz/mud/commit/131c63e539a8e9947835dcc323c8b37562aed9ca), [`5c965a91`](https://github.com/latticexyz/mud/commit/5c965a919355bf98d7ea69463890fe605bcde206), [`582388ba`](https://github.com/latticexyz/mud/commit/582388ba5f95c3efde56779058220dbd7aedee0b), [`582388ba`](https://github.com/latticexyz/mud/commit/582388ba5f95c3efde56779058220dbd7aedee0b), [`6c673325`](https://github.com/latticexyz/mud/commit/6c6733256f91cddb0e913217cbd8e02e6bc484c7), [`cc2c8da0`](https://github.com/latticexyz/mud/commit/cc2c8da000c32c02a82a1a0fd17075d11eac56c3)]: + - @latticexyz/store@2.0.0-next.1 + - @latticexyz/store-sync@2.0.0-next.1 + - @latticexyz/common@2.0.0-next.1 + - @latticexyz/block-logs-stream@2.0.0-next.1 diff --git a/packages/store-indexer/package.json b/packages/store-indexer/package.json index a1dd58cbe7..e23a10802b 100644 --- a/packages/store-indexer/package.json +++ b/packages/store-indexer/package.json @@ -1,6 +1,6 @@ { "name": "@latticexyz/store-indexer", - "version": "2.0.0-next.0", + "version": "2.0.0-next.1", "description": "Minimal Typescript indexer for Store", "repository": { "type": "git", diff --git a/packages/store-sync/CHANGELOG.md b/packages/store-sync/CHANGELOG.md index 3111308f11..f1a0729bce 100644 --- a/packages/store-sync/CHANGELOG.md +++ b/packages/store-sync/CHANGELOG.md @@ -1,5 +1,99 @@ # @latticexyz/store-sync +## 2.0.0-next.1 + +### Major Changes + +- [#1198](https://github.com/latticexyz/mud/pull/1198) [`e86fbc12`](https://github.com/latticexyz/mud/commit/e86fbc1260f698c6a7b6a92c901fefd186c329ff) Thanks [@holic](https://github.com/holic)! - Adds store indexer service package with utils to query the indexer service. + + You can run the indexer locally by checking out the MUD monorepo, installing/building everything, and running `pnpm start:local` from `packages/store-indexer`. + + To query the indexer in the client, you can create a tRPC client with a URL pointing to the indexer service and call the available tRPC methods: + + ```ts + import { createIndexerClient } from "@latticexyz/store-sync/trpc-indexer"; + + const indexer = createIndexerClient({ url: indexerUrl }); + const result = await indexer.findAll.query({ + chainId: publicClient.chain.id, + address, + }); + ``` + + If you're using `syncToRecs`, you can just pass in the `indexerUrl` option as a shortcut to the above: + + ```ts + import { syncToRecs } from "@latticexyz/store-sync/recs"; + + syncToRecs({ + ... + indexerUrl: "https://your.indexer.service", + }); + ``` + +### Minor Changes + +- [#1234](https://github.com/latticexyz/mud/pull/1234) [`131c63e5`](https://github.com/latticexyz/mud/commit/131c63e539a8e9947835dcc323c8b37562aed9ca) Thanks [@holic](https://github.com/holic)! - - Accept a plain viem `PublicClient` (instead of requiring a `Chain` to be set) in `store-sync` and `store-indexer` functions. These functions now fetch chain ID using `publicClient.getChainId()` when no `publicClient.chain.id` is present. + + - Allow configuring `store-indexer` with a set of RPC URLs (`RPC_HTTP_URL` and `RPC_WS_URL`) instead of `CHAIN_ID`. + +- [#1235](https://github.com/latticexyz/mud/pull/1235) [`582388ba`](https://github.com/latticexyz/mud/commit/582388ba5f95c3efde56779058220dbd7aedee0b) Thanks [@holic](https://github.com/holic)! - Export `singletonEntity` as const rather than within the `syncToRecs` result. + + ```diff + - const { singletonEntity, ... } = syncToRecs({ ... }); + + import { singletonEntity, syncToRecs } from "@latticexyz/store-sync/recs"; + + const { ... } = syncToRecs({ ... }); + ``` + +### Patch Changes + +- [#1228](https://github.com/latticexyz/mud/pull/1228) [`57a52608`](https://github.com/latticexyz/mud/commit/57a5260830401c9ad93196a895a50b0fc4a86183) Thanks [@holic](https://github.com/holic)! - Adds `latestBlockNumber` and `lastBlockNumberProcessed` to internal `SyncProgress` component + +- [#1197](https://github.com/latticexyz/mud/pull/1197) [`9e5baf4f`](https://github.com/latticexyz/mud/commit/9e5baf4fff0c60615b8f2b4645fb11cb78cb0bd8) Thanks [@holic](https://github.com/holic)! - Add RECS sync strategy and corresponding utils + + ```ts + import { createPublicClient, http } from 'viem'; + import { syncToRecs } from '@latticexyz/store-sync'; + import storeConfig from 'contracts/mud.config'; + import { defineContractComponents } from './defineContractComponents'; + + const publicClient = createPublicClient({ + chain, + transport: http(), + pollingInterval: 1000, + }); + + const { components, singletonEntity, latestBlock$, blockStorageOperations$, waitForTransaction } = await syncToRecs({ + world, + config: storeConfig, + address: '0x...', + publicClient, + components: defineContractComponents(...), + }); + ``` + +- [#1235](https://github.com/latticexyz/mud/pull/1235) [`582388ba`](https://github.com/latticexyz/mud/commit/582388ba5f95c3efde56779058220dbd7aedee0b) Thanks [@holic](https://github.com/holic)! - Add `startBlock` option to `syncToRecs`. + + ```ts + import { syncToRecs } from "@latticexyz/store-sync/recs"; + import worlds from "contracts/worlds.json"; + + syncToRecs({ + startBlock: worlds['31337'].blockNumber, + ... + }); + ``` + +- [`6c673325`](https://github.com/latticexyz/mud/commit/6c6733256f91cddb0e913217cbd8e02e6bc484c7) Thanks [@holic](https://github.com/holic)! - Add `tableIdToHex` and `hexToTableId` pure functions and move/deprecate `TableId`. + +- Updated dependencies [[`c963b46c`](https://github.com/latticexyz/mud/commit/c963b46c7eaceebc652930936643365b8c48a021), [`3fb9ce28`](https://github.com/latticexyz/mud/commit/3fb9ce2839271a0dcfe97f86394195f7a6f70f50), [`5c965a91`](https://github.com/latticexyz/mud/commit/5c965a919355bf98d7ea69463890fe605bcde206), [`b02f9d0e`](https://github.com/latticexyz/mud/commit/b02f9d0e43089e5f9b46d817ea2032ce0a1b0b07), [`6c673325`](https://github.com/latticexyz/mud/commit/6c6733256f91cddb0e913217cbd8e02e6bc484c7), [`afdba793`](https://github.com/latticexyz/mud/commit/afdba793fd84abf17eef5ef59dd56fabe353c8bd), [`cc2c8da0`](https://github.com/latticexyz/mud/commit/cc2c8da000c32c02a82a1a0fd17075d11eac56c3)]: + - @latticexyz/store@2.0.0-next.1 + - @latticexyz/common@2.0.0-next.1 + - @latticexyz/schema-type@2.0.0-next.1 + - @latticexyz/recs@2.0.0-next.1 + - @latticexyz/block-logs-stream@2.0.0-next.1 + - @latticexyz/protocol-parser@2.0.0-next.1 + ## 2.0.0-next.0 ### Minor Changes diff --git a/packages/store-sync/package.json b/packages/store-sync/package.json index 71418ece36..91db043557 100644 --- a/packages/store-sync/package.json +++ b/packages/store-sync/package.json @@ -1,6 +1,6 @@ { "name": "@latticexyz/store-sync", - "version": "2.0.0-next.0", + "version": "2.0.0-next.1", "description": "Utilities to sync MUD Store events with a client or cache", "repository": { "type": "git", diff --git a/packages/store/CHANGELOG.md b/packages/store/CHANGELOG.md index c38ca4f06f..a432155ba7 100644 --- a/packages/store/CHANGELOG.md +++ b/packages/store/CHANGELOG.md @@ -1,5 +1,22 @@ # Change Log +## 2.0.0-next.1 + +### Patch Changes + +- [#1194](https://github.com/latticexyz/mud/pull/1194) [`c963b46c`](https://github.com/latticexyz/mud/commit/c963b46c7eaceebc652930936643365b8c48a021) Thanks [@dk1a](https://github.com/dk1a)! - Optimize storage library + +- [#1237](https://github.com/latticexyz/mud/pull/1237) [`5c965a91`](https://github.com/latticexyz/mud/commit/5c965a919355bf98d7ea69463890fe605bcde206) Thanks [@alvrs](https://github.com/alvrs)! - Align Store events parameter naming between IStoreWrite and StoreCore + +- [#1210](https://github.com/latticexyz/mud/pull/1210) [`cc2c8da0`](https://github.com/latticexyz/mud/commit/cc2c8da000c32c02a82a1a0fd17075d11eac56c3) Thanks [@dk1a](https://github.com/dk1a)! - - Refactor tightcoder to use typescript functions instead of ejs + - Optimize `TightCoder` library + - Add `isLeftAligned` and `getLeftPaddingBits` common codegen helpers +- Updated dependencies [[`3fb9ce28`](https://github.com/latticexyz/mud/commit/3fb9ce2839271a0dcfe97f86394195f7a6f70f50), [`b02f9d0e`](https://github.com/latticexyz/mud/commit/b02f9d0e43089e5f9b46d817ea2032ce0a1b0b07), [`6c673325`](https://github.com/latticexyz/mud/commit/6c6733256f91cddb0e913217cbd8e02e6bc484c7), [`cc2c8da0`](https://github.com/latticexyz/mud/commit/cc2c8da000c32c02a82a1a0fd17075d11eac56c3)]: + - @latticexyz/common@2.0.0-next.1 + - @latticexyz/schema-type@2.0.0-next.1 + - @latticexyz/config@2.0.0-next.1 + - @latticexyz/gas-report@2.0.0-next.1 + ## 2.0.0-next.0 ### Minor Changes diff --git a/packages/store/package.json b/packages/store/package.json index 5110b51940..fa398731b4 100644 --- a/packages/store/package.json +++ b/packages/store/package.json @@ -1,6 +1,6 @@ { "name": "@latticexyz/store", - "version": "2.0.0-next.0", + "version": "2.0.0-next.1", "description": "Store", "repository": { "type": "git", diff --git a/packages/utils/CHANGELOG.md b/packages/utils/CHANGELOG.md index e0407bdf06..46a5f99e76 100644 --- a/packages/utils/CHANGELOG.md +++ b/packages/utils/CHANGELOG.md @@ -1,5 +1,12 @@ # Change Log +## 2.0.0-next.1 + +### Patch Changes + +- Updated dependencies [[`3fb9ce28`](https://github.com/latticexyz/mud/commit/3fb9ce2839271a0dcfe97f86394195f7a6f70f50), [`6c673325`](https://github.com/latticexyz/mud/commit/6c6733256f91cddb0e913217cbd8e02e6bc484c7), [`cc2c8da0`](https://github.com/latticexyz/mud/commit/cc2c8da000c32c02a82a1a0fd17075d11eac56c3)]: + - @latticexyz/common@2.0.0-next.1 + ## 2.0.0-next.0 ### Patch Changes diff --git a/packages/utils/package.json b/packages/utils/package.json index 9cdd2865aa..3305a17383 100644 --- a/packages/utils/package.json +++ b/packages/utils/package.json @@ -1,6 +1,6 @@ { "name": "@latticexyz/utils", - "version": "2.0.0-next.0", + "version": "2.0.0-next.1", "repository": { "type": "git", "url": "https://github.com/latticexyz/mud.git", diff --git a/packages/world/CHANGELOG.md b/packages/world/CHANGELOG.md index 40ccdaaa50..d4cb3891ea 100644 --- a/packages/world/CHANGELOG.md +++ b/packages/world/CHANGELOG.md @@ -1,5 +1,19 @@ # Change Log +## 2.0.0-next.1 + +### Patch Changes + +- [#1210](https://github.com/latticexyz/mud/pull/1210) [`cc2c8da0`](https://github.com/latticexyz/mud/commit/cc2c8da000c32c02a82a1a0fd17075d11eac56c3) Thanks [@dk1a](https://github.com/dk1a)! - - Refactor tightcoder to use typescript functions instead of ejs + - Optimize `TightCoder` library + - Add `isLeftAligned` and `getLeftPaddingBits` common codegen helpers +- Updated dependencies [[`c963b46c`](https://github.com/latticexyz/mud/commit/c963b46c7eaceebc652930936643365b8c48a021), [`3fb9ce28`](https://github.com/latticexyz/mud/commit/3fb9ce2839271a0dcfe97f86394195f7a6f70f50), [`5c965a91`](https://github.com/latticexyz/mud/commit/5c965a919355bf98d7ea69463890fe605bcde206), [`b02f9d0e`](https://github.com/latticexyz/mud/commit/b02f9d0e43089e5f9b46d817ea2032ce0a1b0b07), [`6c673325`](https://github.com/latticexyz/mud/commit/6c6733256f91cddb0e913217cbd8e02e6bc484c7), [`cc2c8da0`](https://github.com/latticexyz/mud/commit/cc2c8da000c32c02a82a1a0fd17075d11eac56c3)]: + - @latticexyz/store@2.0.0-next.1 + - @latticexyz/common@2.0.0-next.1 + - @latticexyz/schema-type@2.0.0-next.1 + - @latticexyz/config@2.0.0-next.1 + - @latticexyz/gas-report@2.0.0-next.1 + ## 2.0.0-next.0 ### Minor Changes diff --git a/packages/world/package.json b/packages/world/package.json index ed0ad417ba..165935038f 100644 --- a/packages/world/package.json +++ b/packages/world/package.json @@ -1,6 +1,6 @@ { "name": "@latticexyz/world", - "version": "2.0.0-next.0", + "version": "2.0.0-next.1", "description": "World framework", "repository": { "type": "git",