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

feat(react): add support for devtools #10939

Draft
wants to merge 1 commit into
base: main
Choose a base branch
from

Conversation

florian-lefebvre
Copy link
Member

@florian-lefebvre florian-lefebvre commented May 2, 2024

I feel like this is very hacky so I understand if we don't want it in the official integration

Changes

Testing

Manually in the react example

Docs

TBD

Copy link

changeset-bot bot commented May 2, 2024

🦋 Changeset detected

Latest commit: d757108

The changes in this PR will be included in the next version bump.

Not sure what this means? Click here to learn what changesets are.

Click here if you're a maintainer who wants to add another changeset to this PR

@github-actions github-actions bot added pkg: react Related to React (scope) pkg: integration Related to any renderer integration (scope) labels May 2, 2024
'head-inline',
`
const script = document.createElement("script");
script.src = "http://localhost:8097";
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Erm, is this an expected port for the devtools chrome extension? Very surprised to see this 😅 Definitely worth a detailed comment if so

Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Yes I believe it's expected for non supported browsers: https://react.dev/learn/react-developer-tools#safari-and-other-browsers. The docs mention having to insert a script tag but since we can't currently with the integration API, I create the script programmatically. Again, I don't mind not shipping this thing at all because it looks hacky to me

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
pkg: integration Related to any renderer integration (scope) pkg: react Related to React (scope)
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

2 participants