electrode-native icon indicating copy to clipboard operation
electrode-native copied to clipboard

Apply patch for react-native version

Open marc-simon opened this issue 4 years ago • 3 comments

Hi, Is there any way to apply a patch to the react-native version being bundled in ern?

I want to apply the following patch to react-native https://github.com/facebook/react-native/issues/30034#issuecomment-806396274

Can you please suggest on how can i do this?

marc-simon avatar Dec 17 '21 12:12 marc-simon

Hi @marc-simon - Thanks for your question. At the moment it is not possible to modify the version of react-native that is bundled in ern. That's because we use an unmodified packaged artifact (com.walmartlabs.ern:react-native), deployed to maven central.

The solution in the linked issue looks reasonable though, and several other people have shown interests as well. I'd suggest this to be merge to react-native first, which will then also get picked up by ern.

friederbluemle avatar Dec 17 '21 21:12 friederbluemle

Hi @friederbluemle, thanks for the response. Although, it's an important issue to be fixed the fix/patch mentioned seems like a quick fix rather long-term fix as react-native deprecated using scaleY (and it's been more than an year)

Theoretically, if I fork https://github.com/electrode-io/react-native/tree/0.64-ern, patch & publish to my own private maven repo and use that in development ern by making relevant changes in following lines

  1. https://github.com/electrode-io/electrode-native/blob/a091921d16bacf2a793525fe5c278452501515b7/ern-container-gen-android/src/AndroidGenerator.ts#L337
  2. https://github.com/electrode-io/electrode-native/blob/a091921d16bacf2a793525fe5c278452501515b7/ern-api-impl-gen/hull/android/lib/build.gradle#L30

it should work right? Could you please suggest if there's anything else to take care of?

marc-simon avatar Dec 20 '21 12:12 marc-simon

@marc-simon - Yes, that looks like it should work :+1:

friederbluemle avatar Dec 21 '21 14:12 friederbluemle