From df5688cae266bd0dacb6b5b7bcd0348e42bc61dd Mon Sep 17 00:00:00 2001 From: Obinna Ekwuno Date: Wed, 6 Jul 2022 00:24:45 +0400 Subject: [PATCH] docs: add Cloudflare Pages to deploy options (#8927) Co-authored-by: Bjorn Lu --- docs/guide/static-deploy.md | 23 +++++++++++++++++++++++ 1 file changed, 23 insertions(+) diff --git a/docs/guide/static-deploy.md b/docs/guide/static-deploy.md index e3f5731aaae5a6..4fd597a984ae15 100644 --- a/docs/guide/static-deploy.md +++ b/docs/guide/static-deploy.md @@ -187,6 +187,29 @@ The Netlify CLI will share with you a preview URL to inspect. When you are ready $ ntl deploy --prod ``` +## Cloudflare Pages + +1. Install [Wrangler CLI](https://developers.cloudflare.com/workers/wrangler/get-started/). +2. Authenticate Wrangler with your Cloudflare account using `wrangler login`. +3. Run your build command. +4. Deploy using `npx wrangler pages publish dist`. + +```bash +# Install Wrangler CLI +$ npm install -g wrangler + +# Login to Cloudflare account from CLI +$ wrangler login + +# Run your build command +$ npm run build + +# Create new deployment +$ npx wrangler pages publish dist +``` + +After your assets are uploaded, Wrangler will give you a preview URL to inspect your site. When you log into the Cloudflare Pages dashboard, you will see your new project. + ## Google Firebase 1. Make sure you have [firebase-tools](https://www.npmjs.com/package/firebase-tools) installed.