
Research
/Security News
Critical Vulnerability in NestJS Devtools: Localhost RCE via Sandbox Escape
A flawed sandbox in @nestjs/devtools-integration lets attackers run code on your machine via CSRF, leading to full Remote Code Execution (RCE).
blur-react-native
Advanced tools
A powerful React Native library that provides native blur effects for both iOS and Android. Create beautiful, performant blur overlays with various blur types and customization options.
⚠️ New Architecture Only: This library requires React Native 0.76+ with the New Architecture (Fabric) enabled.
npm install blur-react-native
Or with yarn:
yarn add blur-react-native
The library will be automatically linked with React Native 0.76+. You just need to install the pods:
cd ios && pod install
The library will be automatically linked with React Native 0.76+. No additional setup is required.
The library automatically chooses the best blur implementation based on the Android API level:
RenderEffect
for hardware-accelerated blurRenderScript
with ScriptIntrinsicBlur
for GPU-accelerated blurimport React from 'react';
import { View, Text } from 'react-native';
import { BlurView } from 'blur-react-native';
export default function App() {
return (
<View style={{ flex: 1 }}>
<BlurView
blurType="regular"
style={{
position: 'absolute',
top: 100,
left: 20,
right: 20,
height: 200,
borderRadius: 20,
}}
>
<Text style={{ textAlign: 'center', marginTop: 50 }}>
Content on blur background
</Text>
</BlurView>
</View>
);
}
import React from 'react';
import { BlurView, BlurType } from 'blur-react-native';
const blurTypes: BlurType[] = [
'light',
'dark',
'regular',
'systemMaterial',
'systemThickMaterial',
];
export function BlurDemo() {
return (
<View>
{blurTypes.map((type) => (
<BlurView
key={type}
blurType={type}
blurAmount={80}
reducedTransparencyFallbackColor="#FFFFFF"
style={{
height: 100,
margin: 10,
borderRadius: 15,
}}
>
<Text>{type} blur effect</Text>
</BlurView>
))}
</View>
);
}
Prop | Type | Default | Description |
---|---|---|---|
blurType | BlurType | 'regular' | The type of blur effect to apply |
blurAmount | number | 100 | Blur intensity from 0-100 |
reducedTransparencyFallbackColor | string | '#FFFFFF' | Fallback color when reduced transparency is enabled |
style | ViewStyle | undefined | Style object for the blur view |
children | ReactNode | undefined | Child components to render on top of blur |
The following blur types are available on both platforms:
'light'
- Light blur effect with white tint'extraLight'
- Extra light blur effect with minimal tint'dark'
- Dark blur effect with black tint'regular'
- Standard blur effect with neutral tint'prominent'
- Enhanced blur effect with stronger material appearance'systemUltraThinMaterial'
- Ultra-thin system material'systemThinMaterial'
- Thin system material'systemMaterial'
- Standard system material'systemThickMaterial'
- Thick system material'systemChromeMaterial'
- Chrome system material<BlurView blurType="systemMaterial" style={StyleSheet.absoluteFill}>
<View style={styles.modalContent}>
<Text>Modal Content</Text>
</View>
</BlurView>
<BlurView
blurType="systemThickMaterial"
blurAmount={90}
style={{
padding: 20,
borderRadius: 16,
margin: 16,
}}
>
<Text style={styles.cardTitle}>Card Title</Text>
<Text style={styles.cardContent}>Content here</Text>
</BlurView>
<BlurView
blurType="systemChromeMaterial"
style={{
position: 'absolute',
top: 0,
left: 0,
right: 0,
height: 100,
paddingTop: 50,
}}
>
<Text style={styles.navTitle}>Navigation Title</Text>
</BlurView>
RenderEffect
on Android 12+ (API 31+)ScriptIntrinsicBlur
on Android 5.0+ (API 21-30)The library automatically respects the system's "Reduce Transparency" accessibility setting:
UIAccessibilityIsReduceTransparencyEnabled()
reducedTransparencyFallbackColor
to set your preferred fallbackiOS:
UIVisualEffectView
for optimal performance and battery lifeAndroid:
android.graphics.RenderEffect
for hardware-accelerated blurRenderScript
with ScriptIntrinsicBlur
for GPU accelerationHandlerThread
for smooth UINew Architecture not enabled:
This library requires React Native's New Architecture (Fabric). Ensure you have:
Pod install fails:
cd ios && rm -rf Pods Podfile.lock && pod install --repo-update
Build errors:
minSdkVersion
is 21 or highercompileSdkVersion
is 31 or higher for modern blur effectsPerformance issues:
blurAmount
for better performanceSee the contributing guide to learn how to contribute to the repository and the development workflow.
Disclaimer: Most of this README and code was written by vibe coding™ 🎵✨ - if you find a bug, please raise a PR! We promise it's more fun than debugging alone 😄
MIT
Made with create-react-native-library
FAQs
Jellify Blur
The npm package blur-react-native receives a total of 82 weekly downloads. As such, blur-react-native popularity was classified as not popular.
We found that blur-react-native demonstrated a healthy version release cadence and project activity because the last version was released less than a year ago. It has 1 open source maintainer collaborating on the project.
Did you know?
Socket for GitHub automatically highlights issues in each pull request and monitors the health of all your open source dependencies. Discover the contents of your packages and block harmful activity before you install or update your dependencies.
Research
/Security News
A flawed sandbox in @nestjs/devtools-integration lets attackers run code on your machine via CSRF, leading to full Remote Code Execution (RCE).
Product
Customize license detection with Socket’s new license overlays: gain control, reduce noise, and handle edge cases with precision.
Product
Socket now supports Rust and Cargo, offering package search for all users and experimental SBOM generation for enterprise projects.