How to properly deploy the Vue history mode project in the root directory by Nginx

as described in the question

Let"s deploy Vue first. The key code is as follows

index.js under config

clipboard.png

main.js

clipboard.png

nginx

clipboard.png

500

clipboard.png

I want to deploy in the root directory, that is, I can directly enter the address to open the index home page. I don"t want to add a few more paths. The basic things on the Internet are not under the root directory. After I remove them, I seem to have a problem again, so I hope the boss can do me a favor and give me some advice

.
Jun.13,2022

you can start a service directly with a few lines of Node code, and you can rewrite index.html in history mode

.
MySQL Query : SELECT * FROM `codeshelper`.`v9_news` WHERE status=99 AND catid='6' ORDER BY rand() LIMIT 5
MySQL Error : Disk full (/tmp/#sql-temptable-64f5-1b3d206-2c378.MAI); waiting for someone to free some space... (errno: 28 "No space left on device")
MySQL Errno : 1021
Message : Disk full (/tmp/#sql-temptable-64f5-1b3d206-2c378.MAI); waiting for someone to free some space... (errno: 28 "No space left on device")
Need Help?