Appearance
Publish static assets with Cloudflare
Cloudflare publication requires a dedicated Wrangler configuration, and assumed the wrangler npm package is installed and the binary is available in the path. Keep the Worker name, compatibility date, routes, and other deployment settings there. The publisher builds once and passes the actual output directory to Wrangler with --assets; it does not rewrite the authored file.
json
{
"name": "example-client-docs",
"compatibility_date": "2026-09-29"
}Save this as wrangler.jsonc in the project root and make publish_cloudflare discovers it without additional publication metadata. The deploy action supplies the built site through Wrangler's --assets option, so the minimal file does not need assets.directory. The publisher falls back to wrangler.json. Set cloudflare.config only when the file lives elsewhere. The executable defaults to wrangler; an authored Wrangler environment is optional.
json
{
"publish": {
"module": "mkdocs",
"name": "Example::Client",
"cloudflare": {
"config": "deploy/wrangler.docs.jsonc",
"wrangler": "wrangler",
"environment": "production"
}
}
}sh
markdown-publish cloudflare --config doc/project.json
# or, with the MakeMaker adapter:
make publish_cloudflareWARNING
This command deploys to Cloudflare. Review the Worker name, account, routes, environment, and current Wrangler login before running it. Keep tokens and other credentials out of project metadata and source control.