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

[Android] Build fail with React native 0.77 version #2908

Open
1 task
kulak91 opened this issue Jan 23, 2025 · 0 comments
Open
1 task

[Android] Build fail with React native 0.77 version #2908

kulak91 opened this issue Jan 23, 2025 · 0 comments
Labels
bug Something isn't working

Comments

@kulak91
Copy link

kulak91 commented Jan 23, 2025

Description

Due to this change in react native 0.77. React native skia is not building properly.

Locally i applied this patch:

diff --git a/node_modules/@shopify/react-native-skia/android/src/paper/java/com/facebook/react/viewmanagers/SkiaDomViewManagerDelegate.java b/node_modules/@shopify/react-native-skia/android/src/paper/java/com/facebook/react/viewmanagers/SkiaDomViewManagerDelegate.java
index 13828a5..8e86ab2 100644
--- a/node_modules/@shopify/react-native-skia/android/src/paper/java/com/facebook/react/viewmanagers/SkiaDomViewManagerDelegate.java
+++ b/node_modules/@shopify/react-native-skia/android/src/paper/java/com/facebook/react/viewmanagers/SkiaDomViewManagerDelegate.java
@@ -12,9 +12,10 @@ package com.facebook.react.viewmanagers;
 import android.view.View;
 import androidx.annotation.Nullable;
 import com.facebook.react.uimanager.BaseViewManagerDelegate;
-import com.facebook.react.uimanager.BaseViewManagerInterface;
+import com.facebook.react.uimanager.BaseViewManager;
+import com.facebook.react.uimanager.LayoutShadowNode;

-public class SkiaDomViewManagerDelegate<T extends View, U extends BaseViewManagerInterface<T> & SkiaDomViewManagerInterface<T>> extends BaseViewManagerDelegate<T, U> {
+public class SkiaDomViewManagerDelegate<T extends View, U extends BaseViewManager<T, ? extends LayoutShadowNode> & SkiaDomViewManagerInterface<T>> extends BaseViewManagerDelegate<T, U> {
   public SkiaDomViewManagerDelegate(U viewManager) {
     super(viewManager);
   }
diff --git a/node_modules/@shopify/react-native-skia/android/src/paper/java/com/facebook/react/viewmanagers/SkiaPictureViewManagerDelegate.java b/node_modules/@shopify/react-native-skia/android/src/paper/java/com/facebook/react/viewmanagers/SkiaPictureViewManagerDelegate.java
index 9131a9e..27b53c3 100644
--- a/node_modules/@shopify/react-native-skia/android/src/paper/java/com/facebook/react/viewmanagers/SkiaPictureViewManagerDelegate.java
+++ b/node_modules/@shopify/react-native-skia/android/src/paper/java/com/facebook/react/viewmanagers/SkiaPictureViewManagerDelegate.java
@@ -12,9 +12,10 @@ package com.facebook.react.viewmanagers;
 import android.view.View;
 import androidx.annotation.Nullable;
 import com.facebook.react.uimanager.BaseViewManagerDelegate;
-import com.facebook.react.uimanager.BaseViewManagerInterface;
+import com.facebook.react.uimanager.BaseViewManager;
+import com.facebook.react.uimanager.LayoutShadowNode;

-public class SkiaPictureViewManagerDelegate<T extends View, U extends BaseViewManagerInterface<T> & SkiaPictureViewManagerInterface<T>> extends BaseViewManagerDelegate<T, U> {
+public class SkiaPictureViewManagerDelegate<T extends View, U extends BaseViewManager<T, ? extends LayoutShadowNode> & SkiaPictureViewManagerInterface<T>> extends BaseViewManagerDelegate<T, U> {
   public SkiaPictureViewManagerDelegate(U viewManager) {
     super(viewManager);
   }

React Native Skia Version

1.10.2

React Native Version

0.77

Using New Architecture

  • Enabled

Steps to Reproduce

Install latest react-native, skia. Buld android

Snack, Code Example, Screenshot, or Link to Repository

@kulak91 kulak91 added the bug Something isn't working label Jan 23, 2025
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working
Projects
None yet
Development

No branches or pull requests

1 participant