Disclosure: I have no affiliation or investment in any company mentioned in this post. This is just my experience.
I assumed you have some experience with NodeJS, ExpressJS and signed up with Vercel.
Vercel (zeit) has been working fine for me for a while. The problem is there are different ways on the internet to set it up and most of them doesn't work for me anymore, maybe due to changes from Vercel. But I'm glad this setup works now.
In this article, I just want to share my experience and github repository which you can use it to create your own Express NodeJS App and deploy it to Vercel.
Github repository link:
$ npm install vercel -g $ npm install $ vercel
- Vercel will generate ".vercel" directory, don't share or commit this one.
- After deploying, open your URL like this:
- If you're using Typescript, build your source directory, output to "app"
- Update package.json: "main": "app/index.js"
- Map API routes (/api/...) and static (UI) routes (/...).
Now you have a full-stack web application deployed to the Internet using Vercel! Happy coding!
- This official article describes more in details about Vercel and Express - https://vercel.com/guides/using-express-with-vercel
- Github Repo - https://github.com/ngduc/vercel-express