DEV Community

Adithyan A
Adithyan A

Posted on • Originally published at adithyana.hashnode.dev on

Host ReactJS App On GitHub Pages

What is this blog about

In this blog, I am going to tell you how we can host a react-js web app on GitHub Pages

Prerequisite

  • The ReactJS app should have a GitHub repository

  • The GitHub repositories visibility should be public

  • You should know the basics of git

Steps By Step Instruction

  1. Add a remote that points to the GitHub repository

  2. Install the GH-Pages package inside the react app

  3. Add homepage field to the package.json file

  4. Add predeploy and deploy scripts to the package.json scripts section

In my case, it will be

  1. Run the deploy command in terminal

  2. Publishing the newly deployed branch - gh-pages

Top comments (0)