Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

fix(button): fix error Button cannot be used as a JSX component #974

Merged
merged 1 commit into from
Sep 18, 2023

Conversation

congon4tor
Copy link
Contributor

Summarize the changes made and the motivation behind them.

Fix error after updating to v0.6.0 Button cannot be used as a JSX component. Its return type 'ReactNode' is not a valid JSX element.

Reference related issues using # followed by the issue number.

fix #962

If there are breaking API changes - like adding or removing props, or changing the structure of the theme - describe them, and provide steps to update existing code.

Fix error after updating to v0.6.0 Button cannot be used as a JSX component. Its return type
'ReactNode' is not a valid JSX element.

fix themesberg#962
@vercel
Copy link

vercel bot commented Sep 18, 2023

The latest updates on your projects. Learn more about Vercel for Git ↗︎

Name Status Preview Comments Updated (UTC)
flowbite-react ✅ Ready (Inspect) Visit Preview 💬 Add feedback Sep 18, 2023 4:21pm

@codecov
Copy link

codecov bot commented Sep 18, 2023

Codecov Report

Patch coverage: 70.43% and project coverage change: -6.01% ⚠️

Comparison is base (7461173) 99.54% compared to head (a359614) 93.54%.
Report is 71 commits behind head on main.

Additional details and impacted files
@@            Coverage Diff             @@
##             main     #974      +/-   ##
==========================================
- Coverage   99.54%   93.54%   -6.01%     
==========================================
  Files         163      179      +16     
  Lines        6621     7819    +1198     
  Branches      401      434      +33     
==========================================
+ Hits         6591     7314     +723     
- Misses         30      505     +475     
Files Changed Coverage Δ
src/components/Pagination/helpers.ts 100.00% <ø> (ø)
src/components/Toast/theme.ts 100.00% <ø> (ø)
src/components/Datepicker/Datepicker.tsx 28.66% <28.66%> (ø)
src/components/Datepicker/Views/Days.tsx 36.00% <36.00%> (ø)
src/components/Datepicker/Views/Decades.tsx 37.70% <37.70%> (ø)
src/components/Datepicker/Views/Months.tsx 37.70% <37.70%> (ø)
src/components/Datepicker/Views/Years.tsx 37.70% <37.70%> (ø)
src/components/Banner/BannerCollapseButton.tsx 40.90% <40.90%> (ø)
src/components/Datepicker/helpers.ts 60.13% <60.13%> (ø)
src/components/Banner/Banner.tsx 64.70% <64.70%> (ø)
... and 36 more

☔ View full report in Codecov by Sentry.
📢 Have feedback on the report? Share it here.

@rluders
Copy link
Collaborator

rluders commented Sep 18, 2023

I'm too ignorant of React to understand the difference here. So, I'll ask @tulup-conner and @nigellima for help.

Copy link
Collaborator

@nigellima nigellima left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Good catch. LGTM

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Button can't be rendered as it's return type is ReactNode.
3 participants