Add additional prop for button and fab that accept other elements like `a`
See original GitHub issueFor now, button
and fab
render fixed <button>
element.
However, button like components is usually used with <a>
element or another react components as well.
For example, when I want to use react-router’s Link
component with @material/react-button,
it should be possible (component
, tag
prop name is just example):
<Button component={Link} to="/home">button</Button>
// or
<Button tag="a" href="/somewhere">button</Button>
It’s not possible, now.
If it’s an acceptable feature request, I can make a pr.
Thanks.
Issue Analytics
- State:
- Created 5 years ago
- Comments:7 (7 by maintainers)
Top Results From Across the Web
Building a floating action button (FAB) component - web.dev
A foundational overview of how to build color-adaptive, responsive, and accessible FAB components.
Read more >How to extend props for Material-UI components using ...
The following button uses the Link component. It allso uses the Link's specific props with their types. It allso adds its own sesific...
Read more >Add a Floating Action Button - Android Developers
A floating action button (FAB) is a circular button that triggers the primary action in your app's UI. This page shows you how...
Read more >React Floating Action Button (FAB) component - Material UI
A floating action button appears in front of all screen content, typically as a circular shape with an icon in its center. FABs...
Read more >Buttons: floating action button - Material Design
A FAB represents the primary action on a screen. Constructive. A FAB should perform a constructive action (such as create, share, ...
Read more >Top Related Medium Post
No results found
Top Related StackOverflow Question
No results found
Troubleshoot Live Code
Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start FreeTop Related Reddit Thread
No results found
Top Related Hackernoon Post
No results found
Top Related Tweet
No results found
Top Related Dev.to Post
No results found
Top Related Hashnode Post
No results found
Top GitHub Comments
@wesleyabbey Ya I like that. Care to open PR?
What about having an
href
prop that, when passed in, turned the button into an<a/>
tag?