NOW.SH NOTES
A personal collection of Now.sh related information for easy review.
PLEASE NOTE!
This is Work-in-Progress so contents are incomplete and possibly wrong. Apologies!
VuePress Build Steps:
Add dev and build steps in the package.json
{
...
"scripts": {
"dev": "vuepress dev docs",
"build": "vuepress build docs",
},
...
}
1
2
3
4
5
6
7
8
2
3
4
5
6
7
8
Add the
{
...
"scripts": {
"now-build": "npm run build && mv docs/.vuepress/dist dist"
},
...
}
1
2
3
4
5
6
7
2
3
4
5
6
7
then add the /now.json in the root of the project.
{
"version": 2,
"name": "vuepress",
"builds": [
{"src": "package.json", "use": "@now/static-build"}
]
}
1
2
3
4
5
6
7
2
3
4
5
6
7
We are now ready to deploy the app.
$ now
1
Add Now.sh Domain alias
1. Using a now.sh Domain
This method is the easiest way to use a domain name. To obtain a domain name with the now.sh postfix instantly, simply run the following command:
$ now alias https://devnotes-cdd86aryw.now.sh kematzy-devnotes
1
Your users may now access the above deployment URL using https://kematzy-devnotes.now.sh.