hryhoriiK97
expo-paperkit
Swiftโœจ New

Apple PaperKit for Expo/React Native

Last updated Jul 3, 2026
60
Stars
0
Forks
0
Issues
0
Stars/day
Attention Score
41
Language breakdown
No language data available.
โ–ธ Files click to expand
README

expo-paperkit

expo-paperkit

Apple PaperKit markup experience for Expo/React Native โ€” drawings, shapes, and annotations powered by PaperKit (iOS 26+, macOS 26+).

Features

  • โœ๏ธ Full PaperKit drawing canvas with Apple Pencil support
  • ๐Ÿ”ถ Shape, text box, and arrow/line insertion
  • ๐Ÿ’พ Save/restore markup data (base64 serialization)
  • ๐Ÿ–ผ๏ธ Export canvas as PNG or JPG
  • โ†ฉ๏ธ Undo/redo support
  • โš™๏ธ Configurable feature sets, zoom, and canvas size
  • ๐ŸŽจ PKToolPicker integration (iOS) and MarkupToolbar (macOS)
  • ๐Ÿž๏ธ Background image support
  • ๐Ÿ‘๏ธ Read-only mode for viewing saved markup

Requirements

  • iOS 26.0+ or macOS 26.0+
  • Expo SDK 54+
  • React Native 0.81+

Installation

npm install expo-paperkit

or

yarn add expo-paperkit

Run npx expo prebuild to generate the native project, then build with npx expo run:ios or open the .xcworkspace in Xcode.

Note: This library requires native code and will not work in Expo Go.
macOS: For macOS support, use expo-desktop to set up your project. See the apps/macos-example/ directory for a working example.

Quick Start

import { PaperMarkupView, type PaperMarkupRef } from 'expo-paperkit';
import { useRef, useState } from 'react';

export default function App() { const markupRef = useRef<PaperMarkupRef>(null); const [savedData, setSavedData] = useState<string | null>(null);

const handleSave = async () => { const data = await markupRef.current!.save(); setSavedData(data); };

const handleExport = async () => { const uri = await markupRef.current!.exportAsImage('png', 1.0); console.log('Exported to:', uri); };

return ( <PaperMarkupView ref={markupRef} style={{ flex: 1 }} initialData={savedData ?? undefined} allowFingerDrawing featureSet={{ shapes: true, textBoxes: true, arrows: true, }} onMarkupChanged={() => console.log('Markup changed')} /> ); }

Documentation

  • API Reference โ€” Full props, events, ref methods, and types documentation

License

MIT

ยฉ 2026 GitRepoTrend ยท hryhoriiK97/expo-paperkit ยท Updated daily from GitHub