Skip to content

Module NativeStripeSdkModule: TypeScript interfaces extending TurboModule must only contain 'FunctionTypeAnnotation's. Property 'onConfirmHandlerCallback' refers to a 'TSTypeReference' #1977

Open
@tranhl

Description

@tranhl

Describe the bug
Attempting to install @stripe/stripe-react-native v0.48.0 results in the following error on iOS during Pod install:

UnsupportedModulePropertyParserError: Module NativeStripeSdkModule: TypeScript interfaces extending TurboModule must only contain 'FunctionTypeAnnotation's. Property 'onConfirmHandlerCallback' refers to a 'TSTypeReference'.
    at throwIfModuleTypeIsUnsupported (/Users/tranhl/Projects/connecx/app/app/node_modules/@react-native/codegen/lib/parsers/error-utils.js:163:11)
    at buildPropertySchema (/Users/tranhl/Projects/connecx/app/app/node_modules/@react-native/codegen/lib/parsers/parsers-commons.js:472:3)
    at /Users/tranhl/Projects/connecx/app/app/node_modules/@react-native/codegen/lib/parsers/parsers-commons.js:705:24
    at guard (/Users/tranhl/Projects/connecx/app/app/node_modules/@react-native/codegen/lib/parsers/utils.js:26:14)
    at /Users/tranhl/Projects/connecx/app/app/node_modules/@react-native/codegen/lib/parsers/parsers-commons.js:702:14
    at Array.map (<anonymous>)
    at buildModuleSchema (/Users/tranhl/Projects/connecx/app/app/node_modules/@react-native/codegen/lib/parsers/parsers-commons.js:699:6)
    at /Users/tranhl/Projects/connecx/app/app/node_modules/@react-native/codegen/lib/parsers/parsers-commons.js:522:9
    at guard (/Users/tranhl/Projects/connecx/app/app/node_modules/@react-native/codegen/lib/parsers/utils.js:26:14)
    at buildSchemaFromConfigType (/Users/tranhl/Projects/connecx/app/app/node_modules/@react-native/codegen/lib/parsers/parsers-commons.js:521:22) {
  nodes: [ undefined ] 

To Reproduce
Steps to reproduce the behavior:

  1. Initialize an Expo 51 app
  2. npm install @stripe/[email protected] [email protected]
  3. cd ios && pod install

Expected behavior
pod install runs without error

Screenshots
N/A

Desktop (please complete the following information):
N/A

Smartphone (please complete the following information):
N/A

Additional context

  • React Native v0.74 (Old Architecture)
  • Expo SDK v51.0.38
  • Stripe React Native v0.48

Some quick Googling points to this React Native issue as the root cause.

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