Installation
Prerequisites​
Peer Dependencies
Make sure you have these peer dependencies installed in your React Native or Expo project. Using incompatible versions may cause unexpected behavior or crashes:
{
"react": "^18.3.1",
"react-native": "^0.76.9",
"react-native-reanimated": "^3.16.1"
}
Installing prerequisites package​
Recommended Installation
Use the following command to install the required peer dependency:
- Using npm
npm install react-native-reanimated
- Using yarn
yarn add react-native-reanimated
- Using bun
bun add react-native-reanimated
- Using pnpm
pnpm add react-native-reanimated
Expo Setup​
Expo Installation
If you're using Expo, we recommend using expo install
instead of npm install
to ensure compatibility with your Expo SDK version.
Managed Workflow​
- Install the required dependencies:
npx expo install react-native-reanimated
- Update your
babel.config.js
:
module.exports = function (api) {
api.cache(true);
return {
presets: ['babel-preset-expo'],
plugins: ['react-native-reanimated/plugin'],
};
};
Installing Library​
Library Installation
Install the @masumdev/rn-scroll-to-hide
package using your preferred package manager.
Using npm​
npm install @masumdev/rn-scroll-to-hide
Using yarn​
yarn add @masumdev/rn-scroll-to-hide
Using bun​
bun add @masumdev/rn-scroll-to-hide
Using pnpm​
pnpm add @masumdev/rn-scroll-to-hide
Troubleshooting​
Common Issues
- For Reanimated issues, ensure you've rebuilt the app after installing the package
- Make sure all peer dependencies versions match the requirements
- If you encounter "Reanimated plugin not found" error, verify your babel.config.js is properly configured
- Metro bundler cache issues can be resolved by clearing the cache:
npm start -c
- If animations are not working, check that Reanimated is properly configured in your babel.config.js