Visit project on GitHub
Set theme to dark

denoflare site

Develop and deploy a static docs site to Cloudflare Pages

How to use

Define your content as Markdown files in a GitHub repo, and quickly generate a static site in the style of Cloudflare's Docs Engine .

It's very similar to the process of creating a Docs Engine site, but with a bit more configuration.

Importantly, you can host the generated output on Cloudflare Pages , instead of Workers Sites .

Take a look at the source of this site as an example.

Deploy to Cloudflare Pages

Use denoflare site generate inside a custom build.

  • In your Pages deployment, use the following settings:

    • Framework preset: None
    • Build Command: ./
    • Build output directory: /output
  • Create the file in the root of your content repo, for example:

    curl -fsSL | DENO_INSTALL=./deno-v1.21.0 sh -s v1.21.0
    NO_COLOR=1 DENO_VERSION=v1.21.0 DENOFLARE_VERSION=${DENOFLARE_VERSION} ./deno-v1.21.0/bin/deno run --unstable --allow-all site generate . ./output --verbose


$ denoflare site --help
denoflare-site 0.4.5
Develop and deploy a static docs site to Cloudflare Pages

    denoflare site [subcommand] [FLAGS] [OPTIONS] [args]

  • generate - Generate static output for Cloudfare Pages
  • serve - Host static Cloudflare Pages site locally