Deploy your project to the edge

For this exercise you will deploy your project to the edge using Vercel's CDN. During the lesson you will:

Goals

  1. Add your web application to a GitHub repository.
  2. Create a Vercel project.
  3. Connect your Vercel project to your GitHub repository.

Deploying a Uniform-powered web application to Vercel - or to any CDN - doesn't involve any steps that are unique to Uniform. If you are comfortable with deploying a Next.js application to your CDN, you can skip this section.

In addition, there are many ways to deploy an application to a CDN. The steps below describe just one of those options. You aren't required to use this approach.

  1. In GitHub, create a new repository.

    About this step

    These instructions use a repository named uniform-dev-essentials. You can name your repository whatever you like.

  2. In the root folder of your web application, delete the folder .git.

    This may be a hidden folder on your system.

  3. Open a terminal in the root folder of your web application.
  4. Enter the following commands:
    git init git add --all git commit -m "first commit" git branch -M main git remote add origin https://github.com/<YOUR ACCOUNT>/uniform-dev-essentials.git git push -u origin main
  1. Log into your Vercel account.
  2. Add a new project.
  3. Import your Git repository.
  4. On the Configure Project page, add the environment variables from your .env file.
  5. Click Deploy.