mirror of
https://github.com/meshtastic/web.git
synced 2026-07-31 06:56:28 -04:00
Adds two new packages laying the foundation for a domain-driven migration away from @meshtastic/core. packages/sdk - DDD feature slices: device, chat, nodes, channels, config, telemetry, position, traceroute, files. Each with domain/application/infrastructure/state. - Shared kernel under core/: MeshClient orchestrator, Transport interface (byte-compat with existing transport-* packages), EventBus (typed pub/sub), packet codec, Queue, Xmodem, signals helpers, tslog factory. - Signals via @preact/signals-core. Application use-cases return Result<T,E> via better-result; legacy ports keep throwing. - shim/ re-exports the legacy MeshDevice/Types/Utils API so packages/web continues to build unchanged. - createFakeTransport() under @meshtastic/sdk/testing. - 16 vitest tests incl. end-to-end fake-transport integration. packages/sdk-react - MeshProvider + useSignal/useSignalValue/useClient adapters. - Hooks: useDevice, useConnection, useChat, useNodes, useNode, useChannels, useChannel, useConfig, useModuleConfig, useTelemetry, usePosition, useTraceroute, useFileTransfer, useFavoriteNode, useIgnoreNode. - jsdom-backed hook tests. Root README rewritten with packages table, architecture, and workflow.