Open francois08 opened 3 months ago
Related: https://github.com/phoenixframework/phoenix/pull/5820
The main issue I see with wrapping the link component is that we’d need to mirror the API of Phoenix.Component.link/1 and there’s currently no nice way to do this. I didn’t test this but there would probably also be a conflict when use
ing Phoenix.Component.
In generated
CoreComponents
we are provided a set of components encapsulating their TW classes (which avoids us repeating these classes application-wide).I think we should add a
<.link>
component wrapping the built-in link component which allows the developer to customize the styling of the links.This would be more consistent where other basic components such as button, label, etc. have their styling encapsulated (while for
<.link>
, by default in a generated application, we have to copy the TW classes application-wide).Therefore it would be more logical and consistent to have a link component in CoreComponents alongside the other basic components.