Bklit line and area charts for React Native and Expo. Same composable API as the web charts, drawn with Skia and animated on the UI thread with Reanimated.
Beta
The React Native charts are new. Line and area charts are ready to use; the API may still change. Tested on iPhone with Expo SDK 58. Please open an issue if something looks off, especially on Android.
Bklit's React Native charts use the same components and props as the web charts (LineChart, Line, Grid, XAxis, ChartTooltip, and so on). Under the hood they draw with React Native Skia and animate with Reanimated, so scrubbing, springs and morphs run on the UI thread at full frame rate, without re-rendering React.
Try it on your phone
Install Expo Go from the App Store or Google Play.
Open your phone's camera and point it at the code.
Tap the banner to open the Bklit demo in Expo Go.
Drag across a chart to scrub; use two fingers to select a range.
Bklit charts install with the shadcn CLI, which copies the chart files into your project so you can read and change them. It needs a small components.json file in the root of your project (next to package.json). Create it with:
This copies the charts into components/charts (or src/components/charts) and installs what they need:
React Native Skia, Reanimated, Gesture Handler and Worklets. In an Expo project the CLI installs these with npx expo install, so you get the versions that match your Expo SDK.
d3-array, d3-scale and d3-shape, plus their types.
Scrubbing and range selection use Gesture Handler, which needs one wrapper around your whole app. Open your root layout (src/app/_layout.tsx in a new Expo app) and wrap what it returns:
src/app/_layout.tsx
import { GestureHandlerRootView } from "react-native-gesture-handler";export default function RootLayout() { return ( <GestureHandlerRootView style={{ flex: 1 }}> {/* …everything your layout already returns… */} </GestureHandlerRootView> );}
The app crashes or warns about GestureHandlerRootView. Wrap your root layout as shown in step 4.
Expo Go says the project needs a different SDK. Update the Expo Go app from the App Store or Google Play, or upgrade your project with npx expo install expo@latest --fix.
The shadcn CLI asks which component library to use. It didn't find your components.json. Make sure it's in the project root, next to package.json (step 2).
You're not using Expo. Install @shopify/react-native-skia, react-native-reanimated, react-native-gesture-handler and react-native-worklets with your package manager, run npx pod-install for iOS, and follow each library's setup guide (Reanimated needs its Babel plugin). Then add the charts as in step 3.