Without further ado, let’s take a look at what Gitee Pages are.

1. First we go to our own Gitee repository (ignoring the fact that you have already created your own online repository). Under the name of the repository we will find the text of gitee Pages


2. After clicking in, we will see a brief introduction of Gitee Pagesd, whose important function is a small use for displaying static pages


Through the previous two brief introduction, let’s start the actual operation!

                                        

First we build a new branch in our online warehouse

After the online branches are created, how does the local code synchronize the online branches?

(1) :

(2) :

(This synchronizes local code with online code)

Now let’s try using NPM Run build to package the native code

Note: During the packaging process, dist files are not ignored by default, so our online code will not be able to get the latest dist folder. All we need to do is comment out the /dist in.gitignore.



Now you can click upload code to sync with the online repository, at which point you can see the Dist folder on the online repository



Here comes the big one



1. We selected the code branch and changed the deployment directory to dist so that we could ensure that the domain name was accessed directly to the index.html file in the current folder.

2. Click the Update button and wait for Gitee to deploy automatically. After the deployment is complete, an accessible domain name will appear



3. When you visit this domain, there may be a blank page, open the console will find an error. From the console error, we can know that the static resource is not accessible.




                                   

To change the domain name to the name of your current online repository when deploying your production environment, you simply replace the blog in the image with the name of your online repository.




Finally, run the NPM run build again, sync the code up, and then open the Gitee Pages to update the code deployment

Now you can happily show your friends the static pages you have made

skr~skr~