Search code examples
githubcreate-react-native-app

how to git clone a project and use create-react-native-app


We have a school project where we forked a class project into our local repository. Let's call that repo gitLocalHomeWork. That repo just has a few files. We are building a react-native application. We can use the create-react-native-app to create the native app environment.

create-react-native-app gitLocalHomeWork

how do we link or direct the react native app to the github directory?


Solution

  • If you have some files already in the forked repo then you can use a nested folder inside that repo in which you can create react app through create-react-native-app. Below are the steps:

    • Clone your forked repo to your local machine using git clone.
    • Create a nested folder in your cloned repo and cd to it.
    • Use create-react-native-app command to create the react app.
    • Above command will create some new files, add those files to git staging are using git add command.
    • Commit your changes and push to remote.