Socket
Socket
Sign inDemoInstall

@latticexyz/gas-report

Package Overview
Dependencies
Maintainers
3
Versions
1056
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

@latticexyz/gas-report - npm Package Versions

1
106

2.1.1-main-542ea540329fce74d85c74368e26386682e39cce

Diff

alvarius
published 2.1.1-main-5cee9a0ae5a33fb11cda221bc15ad85633a564fd •

alvarius
published 2.1.1-main-fecd002bd86f4ede1799636905163fb373213f75 •

alvarius
published 2.1.1-main-64354814ed325cefd1066282944408de7c40b4a7 •

alvarius
published 2.1.1-main-1b7004b50489351d58adcf7ed2c35e3adcaf4090 •

alvarius
published 2.1.1-main-0b282ad227869383271e7f9709ea9b0ab1a3268d •

alvarius
published 2.1.1-main-86a810488f7ffb481534062c9c3ff170a1120982 •

alvarius
published 2.1.0 •

Changelog

Source

Version 2.1.0

Release date: Mon Aug 05 2024

Minor changes

docs: update resource labels changeset (#2985) (@latticexyz/config, @latticexyz/store, @latticexyz/world)

Tables and systems in config output now include a label property. Labels are now used throughout the codebase as a user-friendly way to reference the given resource: config keys, contract names, generated libraries, etc.

Inside namespaces config output, keys for tables and systems and their filenames will always correspond to their labels. This should make MUD tooling more intuitive and predictable. For backwards compatibility, tables config output still uses namespace-prefixed keys.

Labels replace the previous resource name usage, which is truncated to bytes16 to be used as part of the resource ID and, in the future, may not always be human-readable.

These labels will soon be registered onchain so that developers can initialize a new MUD project from an existing world, generating config and interfaces with user-friendly names.

docs: update namespaces changeset (#2989) (@latticexyz/cli, @latticexyz/store, @latticexyz/world)

MUD projects can now use multiple namespaces via a new top-level namespaces config option.

import { defineWorld } from "@latticexyz/world";

export default defineWorld({
  namespaces: {
    game: {
      tables: {
        Player: { ... },
        Position: { ... },
      },
    },
    guilds: {
      tables: {
        Guild: { ... },
      },
      systems: {
        MembershipSystem: { ... },
        TreasurySystem: { ... },
      },
    },
  },
});

Once you use the top-level namespaces config option, your project will be in "multiple namespaces mode", which expects a source directory structure similar to the config structure: a top-level namespaces directory with nested namespace directories that correspond to each namespace label in the config.

~/guilds
├── mud.config.ts
└── src
    └── namespaces
        ├── game
        │   └── codegen
        │       └── tables
        │           ├── Player.sol
        │           └── Position.sol
        └── guilds
            ├── MembershipSystem.sol
            ├── TreasurySystem.sol
            └── codegen
                └── tables
                    └── Guild.sol

Patch changes

fix(cli,store): don't deploy disabled tables (#2982) (@latticexyz/store)

Disabled deploy of Hooks table, as this was meant to be a generic, codegen-only table.

refactor(store-sync): remove remaining refs to old config (#2938) (@latticexyz/store-sync)

Refactored package to use the new Store/World configs under the hood, removing compatibility layers and improving performance.

refactor(store-sync): remove remaining refs to old config (#2938) (@latticexyz/store-indexer)

Updated return values to match updated types in @latticexyz/store-sync.

refactor(world): update worldgen with namespaces output (#2974) (@latticexyz/world)

Refactored worldgen in preparation for multiple namespaces.

chore(store-sync): simplify types (#2946) (@latticexyz/store-sync)

Adjusted SyncToRecsOptions type intersection to improve TypeScript performance.

refactor(cli): move off of old config (#2941) (@latticexyz/cli)

Refactored package to use the new Store/World configs under the hood, removing compatibility layers.

Removed --srcDir option from all commands in favor of using sourceDirectory in the project's MUD config.

fix: preserve JsDoc on defineWorld output, bump @arktype/util (#2815) (@latticexyz/config, @latticexyz/query, @latticexyz/store, @latticexyz/world)

Bumped @arktype/util and moved evaluate/satisfy usages to its show/satisfy helpers.

refactor(store-sync): use config namespaces for tables (#2963) (@latticexyz/store-sync)

Refactored syncToRecs and syncToZustand to use tables from config namespaces output. This is a precursor for supporting multiple namespaces.

Note for library authors: If you were using createStorageAdapter from @latticexyz/store-sync/recs, this helper no longer appends MUD's built-in tables from Store and World packages. This behavior was moved into syncToRecs for consistency with syncToZustand and makes createStorageAdapter less opinionated.

You can achieve the previous behavior with:

 import { createStorageAdapter } from "@latticexyz/store-sync/recs";
+import { mudTables } from "@latticexyz/store-sync";

 createStorageAdapter({
-  tables,
+  tables: { ...tables, ...mudTables },
   ...
 });

refactor(cli): move off of old config (#2941) (@latticexyz/world)

Refactored how worldgen resolves systems from the config and filesystem.

fix(cli,store): don't deploy disabled tables (#2982) (@latticexyz/cli)

mud deploy will now correctly skip tables configured with deploy: { disabled: true }.

refactor(cli): use config namespaces for tables (#2965) (@latticexyz/cli)

Refactored CLI commands to use tables from config namespaces output. This is a precursor for supporting multiple namespaces.

fix: preserve JsDoc on defineWorld output, bump @arktype/util (#2815) (@latticexyz/common)

Removed evaluate and satisfy type utils in favor of show and satisfy from @arktype/util.

refactor(cli): move off of old config (#2941) (@latticexyz/world-modules)

Moved build scripts to mud build now that CLI doesn't depend on this package.

Removed generated world interfaces as this package isn't meant to be used as a "world", but as a set of individual modules.

refactor(store-sync): move syncToZustand to new config (#2936) (@latticexyz/dev-tools)

Updated Zustand components after changes to syncToZustand.

refactor(cli): remove last ethers usage (#2952) (@latticexyz/cli)

Refactored mud trace command to use Viem instead of Ethers and removed Ethers dependencies from the package.

refactor(store): update tablegen with namespaces output (#2972) (@latticexyz/store)

Refactored tablegen in preparation for multiple namespaces and addressed a few edge cases:

  • User types configured with a relative filePath are now resolved relative to the project root (where the mud.config.ts lives) rather than the current working directory.
  • User types inside libraries now need to be referenced with their fully-qualified code path (e.g. LibraryName.UserTypeName).

chore: bump glob (#2922) (@latticexyz/abi-ts, @latticexyz/cli, @latticexyz/world-modules, @latticexyz/world, create-mud)

Bumped glob dependency.

feat(common): throw instead of truncating namespace (#2917) (@latticexyz/common)

resourceToHex will now throw if provided namespace is >14 characters. Since namespaces are used to determine access control, it's not safe to automatically truncate to fit into bytes14 as that may change the indended namespace for resource access.

refactor(store,world): simplify table shorthands (#2969) (@latticexyz/store, @latticexyz/world)

Refactored how the config handles shorthand table definitions, greatly simplifying the codebase. This will make it easier to add support for multiple namespaces.


alvarius
published 2.1.0-main-7b873b6e419bb319afe9a2f0818b782dbd58744b •

alvarius
published 2.1.0-main-5b13a6cbaef561c85e4145ca74cb262f687e2674 •

SocketSocket SOC 2 Logo

Product

  • Package Alerts
  • Integrations
  • Docs
  • Pricing
  • FAQ
  • Roadmap
  • Changelog

Packages

npm

Stay in touch

Get open source security insights delivered straight into your inbox.


  • Terms
  • Privacy
  • Security

Made with ⚡️ by Socket Inc