BI

b3pay/ic-reactor

Developer tools

このページは AI により自動翻訳されています。技術的な詳細は原文をご確認ください。 原文を見る

20 stars 品質 69 トレンド 30MIT

IC-Reactor: A suite of JavaScript libraries for seamless frontend development on the Internet Computer platform, offering state management, React integration, and core functionalities for efficient...

概要

Type-safe Internet Computer integration for TypeScript and React IC Reactor is a monorepo of libraries for building Internet Computer (ICP) apps with: - end-to-end TypeScript types - TanStack Query-powered caching and refetching - React hook factories (useActorQuery, useActorMutation, etc.) - display-friendly transforms (DisplayReactor) - optional code generation (CLI + Vite plugin) IC Reactor gives you a higher-level API than raw Actor usage while keeping type safety and control: - typed canister method calls - built-in cache keys and invalidation primitives - typed Ok/Err result handling - shared agent + cache management via ClientManager, with Internet Identity in AuthenticationManager - reusable query/mutation objects that work both inside and outside React What changed, per package, is in CHANGELOG.md, including the changes on main that no release carries yet.

README

以下は原文 README の抜粋です。原文を見る。

IC Reactor


ic-reactor 4 is the current release. It is a thin layer over a candid-core generated module, with a guide shipped in @ic-reactor/core (packages/core/llms.txt), and it replaced the 3.x runtime of @ic-reactor/core and @ic-reactor/react with the 4 API. The 3.x line lives on the v3 branch, takes security fixes only, until 90 days after the 4.0 release, and is documented at ic-reactor.b3pay.net/v3.

IC Reactor is a monorepo of libraries for building Internet Computer (ICP) apps in TypeScript. ic-reactor 4 adds, over the module candid-core-cli gen writes for a canister:

  • a client with caller-scoped query keys, for TanStack Query
  • one error union that says whether a failed call may have executed
  • network resolution: mainnet, a local replica, or the ic_env cookie
  • strict token-unit helpers (parseUnits, formatUnits)
  • a test client over a fake replica
  • 'use client' React bindings: a provider, useClient and useAuth

Package Overview

Package Purpose
@ic-reactor/core The client, errors, network and units
@ic-reactor/react 'use client' bindings over core
@ic-reactor/vite-plugin Generates the candid-core module with candid-core-cli gen in a child process, and sets the local ic_env cookie and /api proxy for vite dev

@ic-reactor/parser, @ic-reactor/codegen and @ic-reactor/cli are not part of ic-reactor 4: candid-core-cli gen generates the canister module instead.

GitHub で README 全文を見る

推奨ツール

別のキーワードを試すか、フィルタを外してください。

インストール

npx skillfish add b3pay/ic-reactor
MCP 初心者?mcpskill.org のガイドから始めましょう →