Research
Security News
Malicious npm Package Targets Solana Developers and Hijacks Funds
A malicious npm package targets Solana developers, rerouting funds in 2% of transactions to a hardcoded address.
react-native-gvr
Advanced tools
$ npm install react-native-gvr --save
$ react-native link react-native-gvr
Libraries
➜ Add Files to [your project's name]
node_modules
➜ react-native-gvr
and add RNGvr.xcodeproj
libRNGvr.a
to your project's Build Phases
➜ Link Binary With Libraries
Cmd+R
)<android/app/src/main/java/[...]/MainActivity.java
import com.reactlibrary.RNGvrPackage;
to the imports at the top of the filenew RNGvrPackage()
to the list returned by the getPackages()
methodandroid/settings.gradle
:
include ':react-native-gvr'
project(':react-native-gvr').projectDir = new File(rootProject.projectDir, '../node_modules/react-native-gvr/android')
android/app/build.gradle
:
compile project(':react-native-gvr')
Copy ./node_modules/react-native-gvr/pod_post_install.sh
to ios folder
Create a Podfile in ios folder
target 'myProject' do
pod 'GVRSDK'
# Your 'node_modules' directory is probably in the root of your project,
# but if not, adjust the `:path` accordingly
pod 'React', :path => '../node_modules/react-native', :subspecs => [
'Core',
'RCTActionSheet',
'RCTAnimation',
'RCTGeolocation',
'RCTImage',
'RCTLinkingIOS',
'RCTNetwork',
'RCTSettings',
'RCTText',
'RCTVibration',
'RCTWebSocket',
'BatchedBridge',
'DevSupport' # Include this to enable In-App Devmenu if RN >= 0.43
# Add any other subspecs you want to use in your project
]
# Explicitly include Yoga if you are using RN >= 0.42.0
pod 'Yoga', :path => '../node_modules/react-native/ReactCommon/yoga'
# Execute every pod install
post_install do |installer|
system(". ./pod_post_install.sh")
end
end
Still in ios folder install pods locally
pod install
pod update
myProject.xcworkspace
and under myProject
> Build Settings
under Build Options
set ENABLE BITCODE to NO./android/app/build.gradle
then set minSdkVersion 19
import { VideoView } from 'react-native-gvr'
<VideoView
style={{ height: 300, width: 200 }}
source={{
uri: 'https://raw.githubusercontent.com/googlevr/gvr-ios-sdk/master/Samples/VideoWidgetDemo/resources/congo.mp4',
type: 'mono'
}}
displayMode={'embedded'}
volume={1}
enableFullscreenButton
enableCardboardButton
enableTouchTracking
hidesTransitionView
enableInfoButton={false}
/>
FAQs
A bridge of react-native with google vr
We found that react-native-gvr demonstrated a not healthy version release cadence and project activity because the last version was released 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 malicious npm package targets Solana developers, rerouting funds in 2% of transactions to a hardcoded address.
Security News
Research
Socket researchers have discovered malicious npm packages targeting crypto developers, stealing credentials and wallet data using spyware delivered through typosquats of popular cryptographic libraries.
Security News
Socket's package search now displays weekly downloads for npm packages, helping developers quickly assess popularity and make more informed decisions.