TY

Types

@react-spring/types

Internal package with TypeScript stuff

React Native Libraries
animated
animation
hooks
motion
react
react-native
spring
typescript
velocity
@react-spring/types
Stars
29k
Weekly
5.4M
Open issues
75
Bundle
~15 kB

Installation

npm install @react-spring/types

Code example

import { View, Text, StyleSheet } from "react-native";
import { Types } from "@react-spring/types";

export function Example() {
  return (
    <View style={styles.box}>
      <Text style={styles.title}>Types</Text>
      <Types />
    </View>
  );
}

const styles = StyleSheet.create({
  box: { flex: 1, alignItems: "center", justifyContent: "center", gap: 8 },
  title: { fontSize: 18, fontWeight: "600" },
});

Pros & cons

Pros

  • Actively maintained by Paul Henschel
  • 5.4M weekly downloads. Battle tested
  • First-class TypeScript definitions
  • MIT licensed

Considerations

  • Adds roughly ~15 kB to your bundle
  • Needs client-only rendering in SSR frameworks
  • 75 open issues on GitHub

FAQs

Alternatives & similar libraries