-
Notifications
You must be signed in to change notification settings - Fork 24.4k
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
Don't wrap console methods for metro logging in Chrome debugger #26883
Conversation
Summary: This diff fixes an issue reported in facebook#26788 where logs in the Chrome console were showing a different location than previous versions. In the change here, we stop wrapping the console functions to attach the metro websocket in any environment that isn't a native app environment. We do this by checking `global.nativeLoggingHook` which is bound only by native apps and not environments like the Chrome DevTools. Differential Revision: D17951707 fbshipit-source-id: 64b143c4d256e6ab13150dad2702b12cc4500391
This pull request was exported from Phabricator. Differential Revision: D17951707 |
|
Closes #26788 |
This pull request was successfully merged by @rickhanlonii in 42ac240. When will my fix make it into a release? | Upcoming Releases |
Summary: Pull Request resolved: #26883 This diff fixes an issue reported in #26788 where logs in the Chrome console were showing a different location than previous versions. In the change here, we stop wrapping the console functions to attach the metro websocket in any environment that isn't a native app environment. We do this by checking `global.nativeLoggingHook` which is bound only by native apps and not environments like the Chrome DevTools. Changelog: [General][Fixed] - Fix wrong lines logging in Chrome debugger Reviewed By: cpojer, gaearon Differential Revision: D17951707 fbshipit-source-id: f045ea9abaa8aecc6afb8eca7db9842146a3d872
Summary: Pull Request resolved: facebook/react-native#26883 This diff fixes an issue reported in facebook/react-native#26788 where logs in the Chrome console were showing a different location than previous versions. In the change here, we stop wrapping the console functions to attach the metro websocket in any environment that isn't a native app environment. We do this by checking `global.nativeLoggingHook` which is bound only by native apps and not environments like the Chrome DevTools. Changelog: [General][Fixed] - Fix wrong lines logging in Chrome debugger Reviewed By: cpojer, gaearon Differential Revision: D17951707 fbshipit-source-id: f045ea9abaa8aecc6afb8eca7db9842146a3d872
Summary:
This diff fixes an issue reported in #26788 where logs in the Chrome console were showing a different location than previous versions.
In the change here, we stop wrapping the console functions to attach the metro websocket in any environment that isn't a native app environment. We do this by checking
global.nativeLoggingHook
which is bound only by native apps and not environments like the Chrome DevTools.Differential Revision: D17951707