Ecosyste.ms: Awesome

An open API service indexing awesome lists of open source software.

https://github.com/ghondar/react-native-vlc-player

VLC Player for react-native
https://github.com/ghondar/react-native-vlc-player

android react-native vlc vlc-player

Last synced: 2 months ago
JSON representation

VLC Player for react-native

Lists

README

        

# react-native-vlc-player

## Getting started

`$ npm install react-native-vlc-player --save`

## Dependencies

`$ npm install react-native-vector-icons --save`

### Manual installation

Copy Ionicons.ttf from `node_modules/react-native-vector-icons/Fonts` to `android/app/src/main/assets/fonts`

#### Android

1. Insert the following lines inside the dependencies block in `android/app/build.gradle`:
```Diff
...
allprojects {
...
dependencies {
...
+ maven {
+ url("https://jitpack.io")
+ }
}
}
```

## Usage
```javascript
import React, {Component} from 'react';
import {
StyleSheet,
View
} from 'react-native';
// Import library
import VlcPlayer from 'react-native-vlc-player';

export default class App extends Component {
vlcplayer = React.createRef();

componentDidMount() {
console.log(this.vlcplayer)
}

render() {
return (



);
}
}

const styles = StyleSheet.create({
container: {
flex: 1,
justifyContent: 'center',
alignItems: 'center',
backgroundColor: 'grey',
},
});
```

## Props
```javascript

```

## Static Methods

`seek(seconds)`

```
this.refs['vlcplayer'].seek(0.333);
```

`snapshot(path)`

```
this.refs['vlcplayer'].snapshot(path);
```