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

Add displayName to Link component in React adapter #1512

Merged
merged 1 commit into from
Apr 14, 2023

Conversation

hailwood
Copy link
Contributor

Right now the Inertia Link component doesn't have a displayName set, this doesn't cause any functional issues, but the displayName is often used by devtools to help make things a bit nicer.

The most recent example I've found of this causing issues is in Storybook -
storybookjs/storybook#20920 (comment)

If I use e.g. the Inertia Link component then it's showing as <[Object object] href="/">This is a link</[Object object]>.
While it could be argued that this is a storybook issue, other devtools also use displayName so it's an easy win for Inertia with no downsides.

We merged #351 for similar reasons.

@reinink reinink changed the title Add displayName to Link component Add displayName to Link component in React Adapter Apr 14, 2023
@reinink reinink changed the title Add displayName to Link component in React Adapter Add displayName to Link component in React adapter Apr 14, 2023
@reinink reinink merged commit 9a6258a into inertiajs:master Apr 14, 2023
@reinink
Copy link
Member

reinink commented Apr 14, 2023

Thanks!

@reinink
Copy link
Member

reinink commented Apr 20, 2023

Released: https://github.com/inertiajs/inertia/releases/tag/v1.0.4

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.

2 participants