1.add
scripts{
...
"predeploy": "npm run build",
"deploy":"gh-pages -d build"
...
}
in package.json scripts part.
2.add "homepage":"https://username.github.io/reponame/" in package.json root
{
"name": "wordmemorizer",
"version": "0.1.0",
"private": true,
"homepage":"https://username.github.io/reponame/"
...
}
3. install
npm install -g ghp
npm install --save gh-pages
4. after installation execute npm run deploy
5.after npm run deploy in github repo new branch "gh-pages" automatically will be created.
go to repo settings in github.com and in GitHub Pages section change Source to gh-pages branch, otherwise it will show only readme file
Video:
https://www.youtube.com/watch?v=tf5qFEyOafw
scripts{
...
"predeploy": "npm run build",
"deploy":"gh-pages -d build"
...
}
in package.json scripts part.
2.add "homepage":"https://username.github.io/reponame/" in package.json root
{
"name": "wordmemorizer",
"version": "0.1.0",
"private": true,
"homepage":"https://username.github.io/reponame/"
...
}
3. install
npm install -g ghp
npm install --save gh-pages
4. after installation execute npm run deploy
5.after npm run deploy in github repo new branch "gh-pages" automatically will be created.
go to repo settings in github.com and in GitHub Pages section change Source to gh-pages branch, otherwise it will show only readme file
Video:
https://www.youtube.com/watch?v=tf5qFEyOafw
Comments
Post a Comment