npm package discovery and stats viewer.

Discover Tips

  • General search

    [free text search, go nuts!]

  • Package details

    pkg:[package-name]

  • User packages

    @[username]

Sponsor

Optimize Toolset

I’ve always been into building performant and accessible sites, but lately I’ve been taking it extremely seriously. So much so that I’ve been building a tool to help me optimize and monitor the sites that I build to make sure that I’m making an attempt to offer the best experience to those who visit them. If you’re into performant, accessible and SEO friendly sites, you might like it too! You can check it out at Optimize Toolset.

About

Hi, 👋, I’m Ryan Hefner  and I built this site for me, and you! The goal of this site was to provide an easy way for me to check the stats on my npm packages, both for prioritizing issues and updates, and to give me a little kick in the pants to keep up on stuff.

As I was building it, I realized that I was actually using the tool to build the tool, and figured I might as well put this out there and hopefully others will find it to be a fast and useful way to search and browse npm packages as I have.

If you’re interested in other things I’m working on, follow me on Twitter or check out the open source projects I’ve been publishing on GitHub.

I am also working on a Twitter bot for this site to tweet the most popular, newest, random packages from npm. Please follow that account now and it will start sending out packages soon–ish.

Open Software & Tools

This site wouldn’t be possible without the immense generosity and tireless efforts from the people who make contributions to the world and share their work via open source initiatives. Thank you 🙏

© 2025 – Pkg Stats / Ryan Hefner

reanimated-touchable-scale

v1.0.1

Published

Smooth and perfomant scale up/down animation for your React Native pressable components. Built with [Reanimated](https://docs.swmansion.com/react-native-reanimated/docs) and [Gesture Handler](https://docs.swmansion.com/react-native-gesture-handler/docs).

Readme

reanimated-touchable-scale

Smooth and perfomant scale up/down animation for your React Native pressable components. Built with Reanimated and Gesture Handler.

https://github.com/user-attachments/assets/8478b06e-6686-4679-a57c-7b392ecda5c3

Features

🚀 Performance First

  • Runs animations on the UI thread using Reanimated worklets
  • Zero bridge traffic during animations
  • Smooth 60+ FPS animations even during heavy bridge load

🎯 Purposefully Built

  • Specifically designed for scale animations on touch
  • Optimized spring configurations for natural feeling feedback
  • Works great for buttons, cards, and any pressable components really

💪 Production Ready

  • Built on stable primitives (Reanimated + Gesture Handler)
  • Handles edge cases like rapid taps and interrupted gestures
  • TypeScript support
  • Supports both Old and New Architecture, iOS and Android

🎨 Highly Customizable

  • Configurable scale values and spring animations
  • Supports both JS and UI thread event handlers

🪶 Lightweight

  • Few dependencies (only Reanimated and Gesture Handler)
  • Small implementation (~150 lines of code)
  • No external assets or resources

Installation

yarn add reanimated-touchable-scale react-native-reanimated react-native-gesture-handler

Make sure to follow the setup instructions for:

Usage

import { TouchableScale } from "reanimated-touchable-scale";

export default function MyButton() {
  return (
    <TouchableScale
      pressedScale={0.98}
      onPress={() => console.log('Pressed!')}
    >
      <View style={styles.button}>
        <Text style={styles.text}>Press me</Text>
      </View>
    </TouchableScale>
  );
}

Props

| Prop | Type | Default | Description | | --------------- | -------- | ------- |-------------------------------------------| | children | ReactNode | Required | Content to render inside the touchable component | | pressedScale | number | 0.98 | Scale when pressed | | style | ViewStyle | - | Additional styles | | springPress | SpringConfig | See below* | Configuration for the press animation | | springRelease | SpringConfig | See below* | Configuration for the release animation | | onPress | () => void | - | Called when press is complete (JS thread) | | onPressWorklet | () => void | - | Called when press is complete (UI thread) | | onPressIn | () => void | - | Called when press starts (JS thread) | | onPressInWorklet | () => void | - | Called when press starts (UI thread) | | onPressOut | () => void | - | Called when press ends (JS thread) | | onPressOutWorklet | () => void | - | Called when press ends (UI thread)

*Default spring configuration:

{
  stiffness: 300,
  damping: 22,
  mass: 1.5,
  restSpeedThreshold: 0.001
  // Press spring adds: velocity: -0.5
}