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

Fix Inspector links #929

Draft
wants to merge 1 commit into
base: main
Choose a base branch
from
Draft
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
9 changes: 7 additions & 2 deletions packages/vscode-extension/lib/babel_transformer.js
Original file line number Diff line number Diff line change
Expand Up @@ -104,14 +104,19 @@ function transformWrapper({ filename, src, ...rest }) {
// is experimental as it has some performance implications and may be removed in future versions.
//
const { version } = requireFromAppDir("react-native/package.json");
const rendererFileName = filename.split(path.sep).pop();
if (
version.startsWith("0.74") ||
version.startsWith("0.75") ||
version.startsWith("0.76") ||
version.startsWith("0.77")
) {
const rendererFileName = filename.split(path.sep).pop();
src = `module.exports = require("__RNIDE_lib__/rn-renderer/${rendererFileName}");`;
src = `module.exports = require("__RNIDE_lib__/rn-renderer/react-native-74-77/${rendererFileName}");`;
}
if(
version.startsWith("0.78")
){
src = `module.exports = require("__RNIDE_lib__/rn-renderer/react-native-78/${rendererFileName}");`;
}
}

Expand Down
Loading
Loading