Become a member
to unlock all features

Level Up!

Access all courses & lessons on egghead today and lock-in your price for life.


    Setup React Native Video for iOS and Android

    react-nativeReact Native

    In this lesson we'll install react-native-video with NPM. We'll use the react- native link command to setup all necessary native code. Then we'll import Video from react-native-video and use the <Video/> component in our code!



    Become a Member to view code

    You must be a Pro Member to view code

    Access all courses and lessons, track your progress, gain confidence and expertise.

    Become a Member
    and unlock code for this lesson
    orLog In




    To set up react native video for our react native project we first need to install it from npm. We'll type npm install react-native-video --save.

    Once that is complete, we'll also need to link up the native pieces of the code. We can use that using the react-native CLI and type link, which'll now automatically link up all the Android code and all the OIS code that we need for react native video to work.

    Now that we have it linked we can go ahead and import it and use it like any other react native component. We type importVideo from react-native-video and use it as a video component.