Skip to content

Commit

Permalink
Remove the react.gradle file as it's unused (#35539)
Browse files Browse the repository at this point in the history
Summary:
Pull Request resolved: #35539

This file is unused now that we rely on RNGP. We should be able to remove it
in the next stable release 0.72. In 0.71 we shipped it with a removal warning,
and users should not rely on it anymore.

Changelog:
[Android] [Removed] - Remove the react.gradle file as it's unused

Reviewed By: rshest

Differential Revision: D41655709

fbshipit-source-id: 20860da5e596d35738eea5748c791d3d923dc4fb
  • Loading branch information
cortinico authored and facebook-github-bot committed Dec 5, 2022
1 parent 7933dd7 commit d4a9bdc
Show file tree
Hide file tree
Showing 2 changed files with 0 additions and 487 deletions.
1 change: 0 additions & 1 deletion package.json
Original file line number Diff line number Diff line change
Expand Up @@ -29,7 +29,6 @@
"local-cli",
"React-Core.podspec",
"react-native.config.js",
"react.gradle",
"React.podspec",
"React",
"ReactAndroid",
Expand Down
Loading

6 comments on commit d4a9bdc

@jenzhang2000
Copy link

Choose a reason for hiding this comment

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

@cortinico in Veracode doc https://docs.veracode.com/r/c_compilation_react, it has this instruction
"Edit the Android packager script ./node_modules/react-native/react.gradle to add these modifications to the build script:"
If react.gradle is deprecated, where should I define
def jsBundleMapFile = "${jsBundleFile}.map"
"--sourcemap-output", jsBundleMapFile

Thanks!

@cortinico
Copy link
Contributor Author

Choose a reason for hiding this comment

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

You should reachout to veracode and ask them to update their documentation.
The fact that they ask you to edit a file inside node_modules/react-native/react.gradle was wrong to begin with, as this was a private file.

We refactored everything and we removed this file as it was creating more pain than anything.

I've also looked through their docs but I couldn't understand what they're asking you to do (is really confusing) so I advice you to open an issue.

@veryriskyrisk
Copy link

@veryriskyrisk veryriskyrisk commented on d4a9bdc Sep 6, 2023

Choose a reason for hiding this comment

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

This is a really hacky way to make sure that both JS bundle and its map ends up in APK. @cortinico I'll appreciate sharing if you'd know better way of achieving that, I was trying to do it "properly" by modifying RNGP configuration to no avail as it does not allow overwrite of bundler options, see this ticket: #39290

@veryriskyrisk
Copy link

Choose a reason for hiding this comment

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

@cortinico any chance to have a look at this?

@veryriskyrisk
Copy link

Choose a reason for hiding this comment

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

Oh never mind, just saw you've assigned the issue to yourself. Thank you! 🙇

@cortinico
Copy link
Contributor Author

Choose a reason for hiding this comment

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

Yes it's something in my backlog but it won't make the 0.73 release

Please sign in to comment.