FG
๐Ÿ’ป Software๐ŸŒ Web & Full-StackVercel

'SomeComponent' cannot be used as a JSX component.

Freshover 2 years ago
Mar 14, 20260 views
Confidence Score78%
78%

Problem

Verify canary release - [X] I verified that the issue exists in the latest Next.js canary release Provide environment information [code block] What browser are you using? (if relevant) _No response_ How are you deploying your application? (if relevant) _No response_ Describe the Bug Any components are producing IDE error but builds successfully. [code block] Expected Behavior probably not give an error when using async components Link to reproduction no link To Reproduce [code block]

Error Output

error but builds successfully.

Unverified for your environment

Select your OS to check compatibility.

1 Fix

Canonical Fix
High Confidence Fix
74% confidence92% success rate9 verificationsLast verified Mar 14, 2026

Solution: 'SomeComponent' cannot be used as a JSX component.

Low Risk

I think a fix is upcoming, but pretty much the issue is that TypeScript doesn't understand async components... It always expects JSX as child, not `Promise<JSX>`. Many are type casting the component and exporting that type casted version... I think it might be better to do: [code block] When the types are fixed, the `@ts-expect-error` directive will complain that it is unused... This fix migh

74

Trust Score

9 verifications

92% success
  1. 1

    I think a fix is upcoming, but pretty much the issue is that TypeScript doesn't

    I think a fix is upcoming, but pretty much the issue is that TypeScript doesn't understand async components... It always expects JSX as child, not `Promise<JSX>`.

  2. 2

    Many are type casting the component and exporting that type casted version... I

    Many are type casting the component and exporting that type casted version... I think it might be better to do:

  3. 3

    When the types are fixed, the `@ts-expect-error` directive will complain that it

    When the types are fixed, the `@ts-expect-error` directive will complain that it is unused...

  4. 4

    This fix might come from the next typescript plugin I think, not sure.

    This fix might come from the next typescript plugin I think, not sure.

Validation

Resolved in vercel/next.js GitHub issue #42292. Community reactions: 141 upvotes.

Verification Summary

Worked: 9
Partial: 2
Failed: 1
Last verified Mar 14, 2026

Sign in to verify this fix

Environment

Submitted by

AC

Alex Chen

2450 rep

Tags

nextjsreactssrupstreamlinear:-nextlocked