-
Notifications
You must be signed in to change notification settings - Fork 0
open in editor #34 #53
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
base: main
Are you sure you want to change the base?
Conversation
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Having an issue where when i try to throw an error, i'm getting "Unable to parse stack trace from error object" in the log.
How i did it:
updated my reactotron config file to be this:
import { reactotronRedux } from "reactotron-redux";
const reactotron = Reactotron.configure({
name: "AskSeekKnock",
port: 9292,
onConnect: () => {
Reactotron.log(
`Reactotron app ${Reactotron.options.name} connected to standalone server.`,
);
},
})
.useReactNative({
networking: {
ignoreUrls: /symbolicate/,
},
editor: false, // Disable the built-in editor plugin
errors: {
veto: (frame) => {
// NOTE: Despite what the docs say, the implementation uses filter()
// so return TRUE to KEEP the frame, FALSE to REMOVE it
// Keep frames that are NOT from React Native internals
return !(
frame.fileName.includes("node_modules/react-native/") ||
frame.fileName.includes("node_modules/@react-native/") ||
frame.fileName.includes("node_modules/expo-router/") ||
frame.fileName.includes("node_modules/@expo/") ||
frame.fileName.includes("node_modules/metro/")
);
},
},
})
.use(reactotronRedux())
.connect();
reactotron.use(openInEditor({ url: "http://localhost:8082" })); // MAKE SURE THIS IS THE CORRECT PORT for the metro packager running the mobile app
console.tron = Reactotron;
export default reactotron;
added throw new Error("some error")
to a useEffect that runs only on mount in a modal component in my app
also tried doing throw new Error("some error")
on a button press in that same modal component
@stevenconner I think that is actually a bug in reactotron-react-native right now: infinitered/reactotron#1573 |
good point, not sure how we can test this without having those stack frames to click on though 😅 |
I have an idea of how to fix it here, but unfortunately I think this is blocked until we resolve the issue: infinitered/reactotron#1573 (comment) |
I'll take a stab at it today and hopefully get this unblocked. |
I think I got a fix here: infinitered/reactotron#1588 @silasjmatson if you want to give this a try before this PR gets merged, you can use the test steps from this PR in your test app for reactotron-macos |
Implement Open In Editor functionality:
manual testing
In your test app, place a throw new Error("some error") somewhere you can manually trigger it
In your test app reactotron config, make sure you have the following:
Ensure you have EXPO_EDITOR or EDITOR set to a gui editor that can be called from the terminal.
closes #34