Version Compatibility
Required versions:react-native@>=0.79andreact@>=19- iOS 14 or above
- Android API level 21 or above
- For video support: Android API level 26 or above
react-native@<=0.78 and react@<=18, use @shopify/react-native-skia version 1.12.4 or below.
Supported platforms: iOS, Android, tvOS, macOS, macOS Catalyst, and Web.
Installation
Install the package using your preferred package manager:Using Expo
Expo provides awith-skia template to quickly create a new project:
Bundle Size
Below is the app size increase when adding React Native Skia to your project:| iOS | Android | Web |
|---|---|---|
| 6 MB | 4 MB | 2.9 MB |
iOS Setup
Runpod install in the ios/ directory:
Android Setup
You will need Android NDK installed. If you have Android Studio installed, make sure$ANDROID_NDK is available:
- Go to File > Project Structure
- Select SDK Location
- Download the NDK if needed
Proguard
If you’re using Proguard, add this rule toproguard-rules.pro:
Troubleshooting
For error CMake ‘X.X.X’ was not found:- Open Tools > SDK Manager
- Switch to SDK Tools tab
- Find CMake and click Show Package Details
- Download the compatible version and apply
Web Support
To use React Native Skia in the browser, see Web Support.TV Support
Starting from version 1.9.0, React Native Skia supports TV devices using React Native TVOS. Both Android TV and Apple TV are supported.Not all features have been tested on TV devices. Please report any issues you encounter.
Debugging
We recommend using React Native DevTools to debug your JS code. Alternatively, you can use:Testing with Jest
React Native Skia test mocks use a web implementation that depends on loading CanvasKit. Add tojest.config.js: