Skip to content

Releases: tech-sumit/react-webmcp

v0.2.1

Choose a tag to compare

@tech-sumit tech-sumit released this 20 Feb 17:18

v0.2.0

Choose a tag to compare

@tech-sumit tech-sumit released this 15 Feb 14:29

What's new

Test suite (76 tests, 7 suites)

Comprehensive test coverage using vitest + @testing-library/react:

  • useWebMCPTool — 17 tests (lifecycle, fingerprint stability, execute ref, error handling)
  • useWebMCPContext — 14 tests (provideContext/clearContext, multi-tool, ref-based execute)
  • useToolEvent — 7 tests (event types, filtering, cleanup)
  • WebMCPForm — 10 tests (attributes, events, submit handler, cleanup)
  • WebMCPInput/Select/Textarea — 15 tests (attribute mapping, prop passthrough)
  • WebMCPProvider — 5 tests (availability detection, defaults)
  • ModelContext utilities — 8 tests (API detection, warning helper)

Production-safe logging

  • console.warn and console.error gated behind process.env.NODE_ENV !== 'production'
  • Warnings are stripped from production bundles by all major bundlers

Code quality

  • Cleaner conditional field inclusion using explicit if checks
  • Tests run in CI and publish workflows

v0.1.1

Choose a tag to compare

@tech-sumit tech-sumit released this 15 Feb 12:53

Changes

  • Align types with browser WebIDL — verified against Chromium Blink script_tools source
    • readOnlyHint is now boolean (per AnnotationsDict IDL), not "true" | "false"
    • executeTool() input is string (JSON), returns Promise<string | null>
    • listTools() inputSchema is always string
    • Restored getCrossDocumentScriptToolResult() (used by Model Context Tool Inspector)
  • Mark library extensions — outputSchema, destructiveHint, idempotentHint, cache documented as non-browser extensions
  • Fix StrictMode cleanup in useWebMCPContext
  • Fix useWebMCPContext fingerprint — include outputSchema for consistency with useWebMCPTool

v0.1.0

Choose a tag to compare

@tech-sumit tech-sumit released this 15 Feb 12:12

Initial release of react-webmcp - React hooks and components for the WebMCP standard.