Software Mansion's best practices for gestures in React Native apps using React Native Gesture Handler.

MITAuto-check passedMobile

Install Gestures

skills CLI
$ npx skills add kingstinct/react-native-healthkit --skill gestures -a claude-code

Project install by default; add -g for ~/.claude/skills/.

GitHub CLI
$ gh skill install kingstinct/react-native-healthkit gestures --agent claude-code

Project scope by default; add --scope user for a personal install. Needs GitHub CLI 2.90.0 or later (public preview).

Manual copy
$ git clone --depth 1 https://github.com/kingstinct/react-native-healthkit.git skills-src && mkdir -p .claude/skills && cp -r skills-src/.agents/skills/react-native-best-practices/references/gestures .claude/skills/gestures && rm -rf skills-src

Use ~/.claude/skills/ instead of .claude/skills for a personal install. The folder must contain SKILL.md.

Claude Code skills documentation · loads skills from .claude/skills/

Facts

Skill name
gestures
GitHub stars
715
Used in
1 other repo
Token cost
~1.7k tokens
SKILL.md length
520 words
Files
7
Skills in repo
11
Repo updated
First seen
Licence
MIT

At a glance

Software Mansion's best practices for gestures in React Native apps using React Native Gesture Handler.

  • Implementing tap
  • SKILL.md covers Version Decision Tree, Critical Rules and References
  • Reaches docs.swmansion.com
  • Any touch interaction

What it does

Gestures is an agent skill from kingstinct/react-native-healthkit. Software Mansion's best practices for gestures in React Native apps using React Native Gesture Handler. Use when implementing tap, pan, pinch, rotation, swipe, long press, fling, hover, drag, or any touch interaction. Trigger on: 'gesture handler', 'GestureDetector', 'tap gesture', 'pan gesture', 'pinch gesture', 'rotation gesture', 'long press', 'fling', 'hover gesture', 'swipe', 'pinch to zoom', 'drag', 'touch handling', 'Pressable', 'RectButton', 'Swipeable', 'DrawerLayout', 'VirtualGestureDetector', or any…

Its SKILL.md is about 1.7k tokens, which your agent loads only when the skill is triggered. The skill folder holds 6 other files (for example `continuous-gestures.md`, `gesture-composition.md` and `gestures.md`).

It sits in Mobile, covering Cross-platform mobile apps. It works with React Native and React. The repository describes itself as: HealthKit bindings for React Native with TypeScript. The licence is MIT.

When your agent uses it

  • Implementing tap
  • Any touch interaction
  • : gesture handler
  • GestureDetector

Example prompts

  • “gesture handler”
  • “GestureDetector”
  • “tap gesture”
  • “/gestures”

What it can do on your machine

Read from SKILL.md and the folder at commit 9854ae3. It shows what the files ask for, not the result of running them.

  • Tool permissions

    Pre-approves nothing: there is no allowed-tools line, so your agent's usual permission prompts apply.

    From allowed-tools in the SKILL.md frontmatter.

  • Runs code

    No scripts in the folder and no shell commands in SKILL.md (its code samples are typescript).

    From the folder's file list and the shell code blocks in SKILL.md.

  • Network

    Hosts in commands or code, which the agent is likely to contact:

    • docs.swmansion.com

    From URLs in SKILL.md, links to its own repository left out.

  • Credentials

    Names no API keys, tokens, secrets or passwords.

    From names ending in _API_KEY, _TOKEN, _SECRET, _KEY or _PASSWORD in SKILL.md.

Context cost

Gestures loads about 1.7k tokens when it runs. Until then it costs about 146 tokens; SKILL.md has 520 words of instructions outside code blocks.

Always · name and description, kept in context so the agent knows when to use it
~146
When it runs · the whole SKILL.md, loaded when a task matches
~1.7k

Estimates: characters ÷ 4, the usual rule of thumb; real counts depend on the model's tokenizer. Scripts and assets cost tokens only if the agent reads them.

Safety

Auto-check passed

The automated check found no risky patterns in SKILL.md.

Automated static check — not a guarantee. Review scripts before installing. It scans the text of SKILL.md for risky patterns (piping downloads into a shell, reading credential files, hidden Unicode, destructive commands); files beside SKILL.md are not scanned.

SKILL.md

The full file from kingstinct/react-native-healthkit at commit 9854ae3, republished under its MIT licence (© kingstinct). 520 words, ~1,675 tokens.

Download SKILL.mdSave it as .claude/skills/gestures/SKILL.md (or your agent's skills folder). This skill also uses 6 other files; get the full folder from GitHub.
name
gestures
description
Software Mansion's best practices for gestures in React Native apps using React Native Gesture Handler. Use when implementing tap, pan, pinch, rotation, swipe, long press, fling, hover, drag, or any touch interaction. Trigger on: 'gesture handler', 'GestureDetector', 'tap gesture', 'pan gesture', 'pinch gesture', 'rotation gesture', 'long press', 'fling', 'hover gesture', 'swipe', 'pinch to zoom', 'drag', 'touch handling', 'Pressable', 'RectButton', 'Swipeable', 'DrawerLayout', 'VirtualGestureDetector', or any request to handle user touch input in a React Native app.

React Native Gesture Handler

Software Mansion's production gesture patterns for React Native using Gesture Handler. Never suggest PanResponder when RNGH is available -- it runs on the JS thread and is effectively deprecated.

Version Decision Tree

Check package.json - "react-native-gesture-handler" version
   │
   ├── user asks to migrate v2 -> v3
   │   → webfetch https://docs.swmansion.com/react-native-gesture-handler/docs/guides/upgrading-to-3
   ├── starts with "2." → use builder API (Gesture.Pan(), Gesture.Simultaneous(), useMemo)
   └── starts with "3." → use hook API (usePanGesture(), useSimultaneousGestures())
Key API Differences (v2 vs v3)
Conceptv2 Builder APIv3 Hook API
Create gestureGesture.Pan().onUpdate(...)usePanGesture({ onUpdate: ... })
Compose (simultaneous)Gesture.Simultaneous(a, b)useSimultaneousGestures(a, b)
Compose (race/competing)Gesture.Race(a, b)useCompetingGestures(a, b)
Compose (exclusive)Gesture.Exclusive(a, b)useExclusiveGestures(a, b)
Activation callback.onStart(...)onActivate: ...
Deactivation callback.onEnd(...)onDeactivate: ...
Change data.onChange(...)merged into onUpdate (use changeX, changeY)
Cross-component.simultaneousWithExternalGesture().simultaneousWith()
Cross-component.requireExternalGestureToFail().requireToFail()
Cross-component.blocksExternalGesture().block()
Memoizationwrap in useMemo (mandatory)built into hooks (automatic)
SVG / broken hierarchyGestureDetector (may break hierarchy)InterceptingGestureDetector + VirtualGestureDetector
State managercallback param stateManagerglobal GestureStateManager
ButtonsRectButton, BorderlessButtonLegacyRectButton, LegacyBorderlessButton (originals renamed)

Critical Rules

GestureHandlerRootView is mandatory -- GestureDetector will crash at runtime without it as an ancestor. Place it as close to the app root as possible. With Expo Router, wrap <Stack /> in the root _layout.tsx:

tsx
// app/_layout.tsx
import { Stack } from 'expo-router';
import { GestureHandlerRootView } from 'react-native-gesture-handler';

export default function RootLayout() {
  return (
    <GestureHandlerRootView>
      <Stack />
    </GestureHandlerRootView>
  );
}

With React Navigation (no Expo Router), wrap the <NavigationContainer> children. With bare React Native, wrap the app root component. Nested GestureHandlerRootViews are ignored -- only the topmost instance is used. Default style is { flex: 1 }.

v2: useMemo every gesture -- without it, gesture objects recreate on every render, causing recognizers to re-attach and lose state:

tsx
const pan = useMemo(() => Gesture.Pan().onBegin(...).onUpdate(...).onEnd(...), []);

v3 hook API handles memoization internally.

Never call JS-thread functions directly from gesture callbacks -- when Reanimated is installed, gesture callbacks run on the UI thread (workletized). Calling any non-worklet function (state setters, navigation, audio APIs, native module methods, useCallback handlers) directly from a gesture callback crashes with "Tried to synchronously call a non-worklet function on the UI thread". Wrap every JS-thread call in scheduleOnRN from react-native-worklets:

tsx
import { scheduleOnRN } from 'react-native-worklets';

// WRONG -- crashes: calling JS function directly from UI thread
const gesture = useMemo(() =>
  Gesture.Pan().onUpdate((e) => {
    handleTouch(e.absoluteX, e.absoluteY); // non-worklet function
  }),
[]);

// CORRECT -- schedules JS function on RN thread
const gesture = useMemo(() =>
  Gesture.Pan().onUpdate((e) => {
    scheduleOnRN(handleTouch, e.absoluteX, e.absoluteY);
  }),
[]);

This applies to all gesture callback types including onTouchesDown, onTouchesMove, onTouchesUp, onStart, onUpdate, onEnd, etc. The only code safe to run directly is worklet-compatible code (shared value mutations, other worklet functions).

Scroll containers -- import ScrollView/FlatList from react-native-gesture-handler, not react-native. Use RectButton for tappable items inside scroll containers:

tsx
import { ScrollView, FlatList, RectButton } from 'react-native-gesture-handler';

Never mix React Native touch handlers with RNGH in the same component tree -- causes double-tap bugs and gesture conflicts. Pick one system per app.

Callbacks are auto-workletized -- do not add 'worklet'; to callbacks passed directly (inline) to gesture hooks/builders. The Babel plugin handles this. Only add 'worklet'; to standalone functions assigned to variables before being passed as callbacks.

Show full SKILL.md (133 more words)Show less

References

Load at most one reference file per question. For API signatures and config options, webfetch the documentation pages linked in each reference file.

FileWhen to read
gestures.mdChoosing which gesture type or component to use; callback lifecycle; threading model; GestureStateManager for manual activation; SharedValue in gesture config
tap-handling.mdRectButton, Pressable, tappable items in scroll containers, tap gestures, double-tap, hit slop
continuous-gestures.mdPan (drag), Pinch (zoom), Rotation, Long press, Fling (swipe), Hover; Reanimated integration patterns; offset accumulation; velocity and decay
gesture-composition.mdCombining gestures on one component (Simultaneous/Race/Exclusive); cross-component relations; VirtualGestureDetector for SVG and Text; Pan inside ScrollView
swipeable-and-drawer.mdReanimatedSwipeable for list item actions; ReanimatedDrawerLayout for side menus; custom swipeable with Pan gesture; web scroll compatibility
testing.mdJest setup and mocking; fireGestureHandler for testing gestures; common troubleshooting (multiple instances, gesture conflicts, enabled timing)

© kingstinct, MIT. Rendered from Markdown: HTML in the file is shown as text, images as links, and headings moved down two levels. Raw file

Files

SKILL.md and 6 other files in .agents/skills/react-native-best-practices/references/gestures of kingstinct/react-native-healthkit.

  • SKILL.md
  • continuous-gestures.md
  • gesture-composition.md
  • gestures.md
  • swipeable-and-drawer.md
  • tap-handling.md
  • testing.md

Open the folder on GitHubat commit 9854ae3

Used in 1 other repository

We found 1 copy of this SKILL.md (exact, near-identical or edited) in other folders, from 1 other GitHub owner. This page covers the copy in kingstinct/react-native-healthkit, which our catalogue first saw on October 7, 2026.

Compare with similar skills

Gestures next to the 5 skills that share the most tags, products or categories with it. Stars are the repository's; “used in” counts other GitHub owners with a copy.

Gestures compared with similar skills
SkillStarsUsed inTokensAuto-checkLicenceRepo updated
Gestures this skillkingstinct/react-native-healthkit7151 repos~1.7kAutomated safety check: PassMIT
React Devtoolssanity-io/sanity6.4k3 repos~2.1kAutomated safety check: PassMIT
Screenmapaleqsio/screenmap239—~7.2kAutomated safety check: PassMIT
Community Migrationjingjing2222/react-native-nitro-geolocation116—~3.5kAutomated safety check: PassMIT
Lovdacnlovdacn/ui107—~3.9kAutomated safety check: PassMIT
Argent React Native Optimizationbbplayer-app/BBPlayer1.1k—~1.3kAutomated safety check: PassMIT

Similar skills

  • React Devtools

    sanity-io/sanity

    Official

    React DevTools CLI for AI agents. An agent skill from sanity-io/sanity.

    6.4k GitHub starsUsed in 3 repos~2.1k tokens
    MobileAuto-check passed
  • Screenmap

    aleqsio/screenmap

    Generate a visual navigation map of an Expo / React Native or NativeScript app.

    239 GitHub stars~7.2k tokensUpdated 3 days ago
    MobileAuto-check passed
  • Community Migration

    jingjing2222/react-native-nitro-geolocation

    Migrate React Native apps from @react-native-community/geolocation to react-native-nitro-geolocation.

    116 GitHub stars~3.5k tokensUpdated 24 days ago
    MobileAuto-check passed
  • Lovdacn

    lovdacn/ui

    Manages lovdacn (lvcn) components and projects for Expo & React Native — adding, initializing, fixing, debugging, styling, theming, and composing UI with NativeWind or Uniwind.

    107 GitHub stars~3.9k tokensUpdated 1 mo ago
    MobileAuto-check passed
  • Optimizes a React Native app by profiling first to find real bottlenecks, then sweeping for mechanical issues.

    1.1k GitHub stars~1.3k tokensUpdated yesterday
    MobileAuto-check passed
  • React Composition Structure

    fluid-design-io/payload-better-auth-starter

    React and React Native file-system architecture patterns that scale.

    120 GitHub stars~899 tokensUpdated 3 days ago
    MobileAuto-check passed

More from kingstinct/react-native-healthkit

All 11 skills in this repo
  • React Native Healthkit

    kingstinct/react-native-healthkit

    How to use @kingstinct/react-native-healthkit (and its sibling @react-native-healthkit/health-records) to read, write and subscribe to Apple HealthKit data from React Native / Expo apps.

    715 GitHub stars~1.6k tokensUpdated yesterday
    Auto-check passed
  • Expo Deployment

    kingstinct/react-native-healthkit

    Deploying Expo apps to iOS App Store, Android Play Store, web hosting, and API routes

    715 GitHub starsUsed in 4 repos~930 tokens
    Auto-check passed
  • React Native Healthkit Contributing

    kingstinct/react-native-healthkit

    How to change the react-native-healthkit monorepo itself (packages/core, packages/react-native-healthkit, packages/health-records, apps/example).

    715 GitHub stars~1.3k tokensUpdated yesterday
    Auto-check passed
  • Multithreading

    kingstinct/react-native-healthkit

    Software Mansion's best practices for multithreading in React Native apps using react-native-worklets.

    715 GitHub starsUsed in 1 repo~1.1k tokens
    Auto-check passed
  • Expo Dev Client

    kingstinct/react-native-healthkit

    Build and distribute Expo development clients locally or via TestFlight

    715 GitHub starsUsed in 5 repos~879 tokens
    Auto-check passed
  • Rich Text

    kingstinct/react-native-healthkit

    Software Mansion's best practices for rich text in React Native using react-native-enriched and react-native-enriched-markdown.

    715 GitHub stars~3.1k tokensUpdated yesterday
    Auto-check passed

Categories

Questions about Gestures

What does Gestures do?

Software Mansion's best practices for gestures in React Native apps using React Native Gesture Handler. Gestures is an agent skill from kingstinct/react-native-healthkit. Software Mansion's best practices for gestures in React Native apps using React Native Gesture Handler.

When should I use Gestures?

Gestures fits situations like: implementing tap; any touch interaction; : gesture handler; gestureDetector.

How do I install Gestures in Claude Code?

Run `npx skills add kingstinct/react-native-healthkit --skill gestures -a claude-code`. Or copy the skill folder (.agents/skills/react-native-best-practices/references/gestures in kingstinct/react-native-healthkit) into .claude/skills/gestures in your project. Claude Code loads it when a task matches its description.

How do I install Gestures in Codex?

Run `npx skills add kingstinct/react-native-healthkit --skill gestures -a codex`. Or copy the skill folder (.agents/skills/react-native-best-practices/references/gestures in kingstinct/react-native-healthkit) into .agents/skills/gestures in your project. Codex loads it when a task matches its description.

Can I use Gestures in Cursor, Gemini CLI or GitHub Copilot?

Cursor, Gemini CLI, GitHub Copilot and OpenCode also load SKILL.md folders. With the skills CLI, run `npx skills add kingstinct/react-native-healthkit --skill gestures -a cursor` (or -a gemini-cli, github-copilot or opencode for the others). To copy it by hand, put the folder in .cursor/skills/gestures, .gemini/skills/gestures, .github/skills/gestures and .opencode/skills/gestures in your project.

What does Gestures need to run?

SKILL.md names no scripts, command-line tools or credentials: Gestures is instructions for the agent only.

Does Gestures access the network?

SKILL.md names 1 domain. In commands or code: docs.swmansion.com; the agent is likely to contact it when it follows the instructions. This is read from the text; nothing was executed.

Is Gestures safe to install?

Our automated static check of SKILL.md found no risky patterns, such as piping downloads into a shell, reading credential files or hidden Unicode. It is not a guarantee. Review the folder before installing.

What licence does Gestures use?

Gestures is published under the MIT licence (the repository's licence). It allows redistribution, so the full SKILL.md is shown on this page.

How many tokens does Gestures use?

About 1.7k tokens (SKILL.md is roughly 6.7k characters). Agents keep only the skill's name and description in context until a task matches; then they load SKILL.md in full.

What are the alternatives to Gestures?

Skills that share tags, products or a category with Gestures: React Devtools (sanity-io/sanity, 6.4k stars), Screenmap (aleqsio/screenmap, 239 stars), Community Migration (jingjing2222/react-native-nitro-geolocation, 116 stars) and Lovdacn (lovdacn/ui, 107 stars). The comparison table on this page puts their stars, adoption, token cost, safety result and licence side by side.

Who maintains Gestures?

kingstinct (a GitHub organization) maintains it in kingstinct/react-native-healthkit, which has 715 GitHub stars. The repository holds 11 skills in this directory. The repository was last updated on October 6, 2026.

Source: kingstinct/react-native-healthkit on GitHub. Facts on this page come from the repository at the commit we read; the author's words are quoted as theirs.