Skip to content

Navigation Menu

Search code, repositories, users, issues, pull requests...

Provide feedback

We read every piece of feedback, and take your input very seriously.

Saved searches

Use saved searches to filter your results more quickly

Appearance settings

Component cannot be used as a JSX component #432

Copy link
Copy link
Open
@DeckerCHAN

Description

@DeckerCHAN
Issue body actions

I have got an error on create-react-app project with the latest core UI.

How to reproduce:

  1. Create default react ts sandbox.
  2. Add "@coreui/coreui": "^5.3.2", "@coreui/react": "^5.5.0", to package.json.
  3. Use CButton in the App.tsx

Got compile error:

'CButton' cannot be used as a JSX component.
  Its return type 'ReactNode' is not a valid JSX element.
    Type 'undefined' is not assignable to type 'Element | null'.typescript(2786)

https://codesandbox.io/p/sandbox/jr4t78?file=%2Fsrc%2FApp.tsx%3A9%2C8

Image

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

      Morty Proxy This is a proxified and sanitized view of the page, visit original site.