Gathering detailed insights and metrics for @react-native-masked-view/masked-view
Gathering detailed insights and metrics for @react-native-masked-view/masked-view
Gathering detailed insights and metrics for @react-native-masked-view/masked-view
Gathering detailed insights and metrics for @react-native-masked-view/masked-view
React Native Masked View Library
npm install @react-native-masked-view/masked-view
Typescript
Module System
Node Version
NPM Version
JavaScript (55.92%)
Java (28.88%)
Objective-C (10.75%)
Ruby (4.45%)
Total Downloads
0
Last Day
0
Last Week
0
Last Month
0
Last Year
0
MIT License
1,071 Stars
176 Commits
128 Forks
10 Watchers
9 Branches
33 Contributors
Updated on Jul 12, 2025
Latest Version
0.3.2
Package Id
@react-native-masked-view/masked-view@0.3.2
Unpacked Size
57.62 kB
Size
36.01 kB
File Count
20
NPM Version
10.1.0
Node Version
20.8.1
Published on
Nov 04, 2024
Cumulative downloads
Total Downloads
Last Day
0%
NaN
Compared to previous day
Last Week
0%
NaN
Compared to previous week
Last Month
0%
NaN
Compared to previous month
Last Year
0%
NaN
Compared to previous year
MaskedView
Provides a React component that renders a masked view.
1yarn add @react-native-masked-view/masked-view
or
1npm install --save @react-native-masked-view/masked-view
Linking the package manually is not required anymore with Autolinking.
Remember to install the pod with:
1npx pod-install
You then need to link the native parts of the library for the platforms you are using. The easiest way to link the library is using the CLI tool by running this command from the root of your project:
1react-native link @react-native-masked-view/masked-view
Import the MaskedView
component from @react-native-masked-view/masked-view
and use it like so:
1import React from 'react'; 2import { Text, View } from 'react-native'; 3import MaskedView from '@react-native-masked-view/masked-view'; 4 5const App = () => { 6 return ( 7 <MaskedView 8 style={{ flex: 1, flexDirection: 'row', height: '100%' }} 9 maskElement={ 10 <View 11 style={{ 12 // Transparent background because mask is based off alpha channel. 13 backgroundColor: 'transparent', 14 flex: 1, 15 justifyContent: 'center', 16 alignItems: 'center', 17 }} 18 > 19 <Text 20 style={{ 21 fontSize: 60, 22 color: 'black', 23 fontWeight: 'bold', 24 }} 25 > 26 Basic Mask 27 </Text> 28 </View> 29 } 30 > 31 {/* Shows behind the mask, you can put anything here, such as an image */} 32 <View style={{ flex: 1, height: '100%', backgroundColor: '#324376' }} /> 33 <View style={{ flex: 1, height: '100%', backgroundColor: '#F5DD90' }} /> 34 <View style={{ flex: 1, height: '100%', backgroundColor: '#F76C5E' }} /> 35 <View style={{ flex: 1, height: '100%', backgroundColor: '#e1e1e1' }} /> 36 </MaskedView> 37 ); 38} 39 40export default App
The following image demonstrates that you can put almost anything behind the mask. The three examples shown are masked <View>
, <Text>
, and <Image>
.
maskElement
Type | Required |
---|---|
element | Yes |
androidRenderingMode
By default hardware
rendering mode will be used for best performance, however if you need to animate your maskElement
then you’ll need to switch to software
to get your mask to update. This prop only affects Android.
Type | Required | Default |
---|---|---|
software , hardware | No | hardware |
No vulnerabilities found.
Reason
no dangerous workflow patterns detected
Reason
license file detected
Details
Reason
binaries present in source code
Details
Reason
Found 10/19 approved changesets -- score normalized to 5
Reason
0 commit(s) and 0 issue activity found in the last 90 days -- score normalized to 0
Reason
detected GitHub workflow tokens with excessive permissions
Details
Reason
dependency not pinned by hash detected -- score normalized to 0
Details
Reason
no effort to earn an OpenSSF best practices badge detected
Reason
security policy file not detected
Details
Reason
project is not fuzzed
Details
Reason
SAST tool is not run on all commits -- score normalized to 0
Details
Reason
15 existing vulnerabilities detected
Details
Score
Last Scanned on 2025-06-30
The Open Source Security Foundation is a cross-industry collaboration to improve the security of open source software (OSS). The Scorecard provides security health metrics for open source projects.
Learn More