Skip to content

Upgrade Web SDK to React 19 and ReScript 12 #1711

Description

@ArushKapoorJuspay

Summary

Modernize the HyperSwitch Web SDK build stack to React 19 and ReScript 12 while preserving existing SDK behavior and merchant-facing APIs.

Goals

  • Upgrade React and React DOM to 19.2.8.
  • Upgrade ReScript to 12.3.0.
  • Upgrade @rescript/react to 0.15.0.
  • Add @rescript/runtime 12.3.0.
  • Preserve classic JSX mode and Jotai store isolation.
  • Maintain existing v1 and v2 SDK behavior.
  • Update the React demo and wrapper integration.
  • Preserve existing Promise rejection semantics.

Acceptance Criteria

  • ReScript compilation succeeds.
  • Default v1 and v2 production builds succeed.
  • Existing lint checks pass.
  • React demo v1 and v2 builds succeed.
  • Dependency trees contain no invalid peer dependencies.
  • Promise rejection handling supports null, undefined, JavaScript values, native errors, JsExn, and ReScript exceptions.
  • Existing merchant-facing APIs remain unchanged.

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions