react-native-fast-animate 0.1.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/LICENSE +20 -0
- package/README.md +86 -0
- package/lib/module/animations.js +1984 -0
- package/lib/module/animations.js.map +1 -0
- package/lib/module/index.js +110 -0
- package/lib/module/index.js.map +1 -0
- package/lib/module/package.json +1 -0
- package/lib/module/types.js +4 -0
- package/lib/module/types.js.map +1 -0
- package/lib/typescript/package.json +1 -0
- package/lib/typescript/src/animations.d.ts +5 -0
- package/lib/typescript/src/animations.d.ts.map +1 -0
- package/lib/typescript/src/index.d.ts +23 -0
- package/lib/typescript/src/index.d.ts.map +1 -0
- package/lib/typescript/src/types.d.ts +23 -0
- package/lib/typescript/src/types.d.ts.map +1 -0
- package/package.json +161 -0
- package/src/animations.ts +1421 -0
- package/src/index.tsx +125 -0
- package/src/types.ts +327 -0
package/LICENSE
ADDED
|
@@ -0,0 +1,20 @@
|
|
|
1
|
+
MIT License
|
|
2
|
+
|
|
3
|
+
Copyright (c) 2026 Muhammet Yesil
|
|
4
|
+
Permission is hereby granted, free of charge, to any person obtaining a copy
|
|
5
|
+
of this software and associated documentation files (the "Software"), to deal
|
|
6
|
+
in the Software without restriction, including without limitation the rights
|
|
7
|
+
to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
|
|
8
|
+
copies of the Software, and to permit persons to whom the Software is
|
|
9
|
+
furnished to do so, subject to the following conditions:
|
|
10
|
+
|
|
11
|
+
The above copyright notice and this permission notice shall be included in all
|
|
12
|
+
copies or substantial portions of the Software.
|
|
13
|
+
|
|
14
|
+
THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
|
|
15
|
+
IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
|
|
16
|
+
FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
|
|
17
|
+
AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
|
|
18
|
+
LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
|
|
19
|
+
OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
|
|
20
|
+
SOFTWARE.
|
package/README.md
ADDED
|
@@ -0,0 +1,86 @@
|
|
|
1
|
+
# react-native-fast-animate
|
|
2
|
+
|
|
3
|
+
🚀 High-performance, lightweight, and extremely comprehensive animation library for React Native. Support for **300+ animations** on the UI thread using Native Driver.
|
|
4
|
+
|
|
5
|
+
[](https://www.npmjs.com/package/react-native-fast-animate)
|
|
6
|
+
[](https://www.npmjs.com/package/react-native-fast-animate)
|
|
7
|
+
[](https://github.com/argedan/react-native-fast-animate/blob/main/LICENSE)
|
|
8
|
+
|
|
9
|
+
## ✨ Features
|
|
10
|
+
|
|
11
|
+
- 🏎️ **Native Performance:** Animations run on the native thread (60/120 FPS).
|
|
12
|
+
- 📦 **Multi-Component Support:** Specialized components for `View`, `Text`, and `Image`.
|
|
13
|
+
- 🌈 **300+ Animations:** From basic fades to complex 3D-like physics-based movements.
|
|
14
|
+
- ⚡ **Lightweight:** Zero dependencies other than React Native.
|
|
15
|
+
- 🔷 **TypeScript:** Fully typed with autocompletion for all animation types.
|
|
16
|
+
- 🔄 **Infinite & Looping:** Easily create continuous attention-seekers.
|
|
17
|
+
|
|
18
|
+
## 📦 Installation
|
|
19
|
+
|
|
20
|
+
```sh
|
|
21
|
+
npm install react-native-fast-animate
|
|
22
|
+
# or
|
|
23
|
+
yarn add react-native-fast-animate
|
|
24
|
+
```
|
|
25
|
+
|
|
26
|
+
## 🚀 Usage
|
|
27
|
+
|
|
28
|
+
### Simple View Animation
|
|
29
|
+
```tsx
|
|
30
|
+
import FastAnimate from 'react-native-fast-animate';
|
|
31
|
+
|
|
32
|
+
const MyComponent = () => (
|
|
33
|
+
<FastAnimate type="fadeInUp" duration={1000}>
|
|
34
|
+
<View style={style.box} />
|
|
35
|
+
</FastAnimate>
|
|
36
|
+
);
|
|
37
|
+
```
|
|
38
|
+
|
|
39
|
+
### Specialized Components
|
|
40
|
+
```tsx
|
|
41
|
+
// Animated Text
|
|
42
|
+
<FastAnimate.Text type="tada" infinite style={{fontSize: 20}}>
|
|
43
|
+
Look at me!
|
|
44
|
+
</FastAnimate.Text>
|
|
45
|
+
|
|
46
|
+
// Animated Image
|
|
47
|
+
<FastAnimate.Image
|
|
48
|
+
source={{uri: '...'}}
|
|
49
|
+
type="bounce"
|
|
50
|
+
style={{width: 50, height: 50}}
|
|
51
|
+
/>
|
|
52
|
+
```
|
|
53
|
+
|
|
54
|
+
### Advanced Props
|
|
55
|
+
| Prop | Type | Default | Description |
|
|
56
|
+
| --- | --- | --- | --- |
|
|
57
|
+
| `type` | `AnimationType` | `'fadeIn'` | One of 300+ animation names |
|
|
58
|
+
| `duration` | `number` | `500` | Animation duration in ms |
|
|
59
|
+
| `delay` | `number` | `0` | Delay before start in ms |
|
|
60
|
+
| `infinite` | `boolean` | `false` | Loops the animation forever |
|
|
61
|
+
| `autoStart` | `boolean` | `true` | Starts animation on mount |
|
|
62
|
+
| `damping` | `number` | `10` | Spring friction (for bounce/fling types) |
|
|
63
|
+
| `stiffness` | `number` | `100` | Spring tension (for bounce/fling types) |
|
|
64
|
+
|
|
65
|
+
## 🎬 Animation Categories
|
|
66
|
+
|
|
67
|
+
- **Fades:** `fadeIn`, `fadeInUp`, `fadeOutRight`, etc.
|
|
68
|
+
- **Slides:** `slideInUp`, `slideOutLeft`, `slideInTopRight`, etc.
|
|
69
|
+
- **Zooms:** `zoomIn`, `zoomOutDown`, `zoomInRotate`, etc.
|
|
70
|
+
- **Bounces:** `bounceIn`, `bounceOutUp`, `bounceInTopLeft`, etc.
|
|
71
|
+
- **3D & Perspective:** `flipInX`, `doorOpenLeft`, `perspectiveFlipY`, `rollIn`, etc.
|
|
72
|
+
- **Attention Seekers:** `pulse`, `shake`, `tada`, `jello`, `heartBeat`, `rubberBand`, etc.
|
|
73
|
+
- **Specials:** `jackInTheBox`, `hinge`, `newspaper`, `spiralIn`, `ufo`, `ghost`, etc.
|
|
74
|
+
- **Continuous:** `float`, `sway`, `vibrate`, `beat`, `shimmer`, etc.
|
|
75
|
+
|
|
76
|
+
## 🛠 Contributing
|
|
77
|
+
|
|
78
|
+
See the [contributing guide](CONTRIBUTING.md) to learn how to contribute to the repository and the development workflow.
|
|
79
|
+
|
|
80
|
+
## 📄 License
|
|
81
|
+
|
|
82
|
+
MIT
|
|
83
|
+
|
|
84
|
+
---
|
|
85
|
+
|
|
86
|
+
Made with ❤️ by [Argedan](https://argedan.com)
|