cashflowy / switchless

component library using mui/joy
2 stars 0 forks source link

Link #12

Closed Fahimansari closed 1 month ago

Fahimansari commented 2 months ago

export default LinkDemo () { return <Link href='/orgs' component={Button} onClick={() => 'I clicked'} }

Pete-Sony commented 2 months ago

Correct me if I am wrong. You want to create a link component that can take any form- Button, Text etc And you want ot control the styling of that component using sx props.

Pete-Sony commented 2 months ago

Could you eleaborate more on why you want to pass the component prop. I feel like it complicates the Link component more. if in need we could write different components with Link attributes

Fahimansari commented 2 months ago

I need it so that I can get the styling of other components. I think getting the styling of button for a link will solve my problem