-
Notifications
You must be signed in to change notification settings - Fork 83
feat(button): add the onClick attribute on link #333
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
Conversation
|
@ddecrulle j'ai une erreur typescript de mon coté :
Voici le code :
Il me dit bien que onClick n'est pas présent dans mon cas. |
Hello @m-maillot, the props of the Link component is something that is suposed to be provided by you. |
What routing lib integration do you implement? |
I use next.js app routing |
can you link to your startDsfr.ts setup? |
So just to make sure, I tried in the Starter for Next App Router and I'm not getting any type error: ![]() Can you maybe fork https://github.com/garronej/react-dsfr-next-appdir-demo, make the change that doesn't work and share it with us? |
Ok, I see... it's my fault. In my sample, I use linkProps and onClick at the same time :
Delete the onClick attribute and it works well ! Sorry 🙇 |
Haha no worries. |
On souhaite pouvoir suivre les clicks sur nos liens. Pour cela, on utilise le onClick sur l'attribut HTML pour alerter notre solution de tracking.
Je pense qu'ajouter la possibilité de définir le onClick sur un button de type lien est une bonne chose.