Prompt Buddy logoPrompt Buddy

cloudflare · Cloudflare Workers Docs

Workers Custom builds

Configures custom compilation steps for Worker projects by defining a build command, working directory, and watch directory within the Wrangler configuration file.

Import to Prompt Buddy

Derived skill

Files assembled from official documentation

Viewing SKILL.md

Workers Custom builds

Configures custom compilation steps for Worker projects by defining a build command, working directory, and watch directory within the Wrangler configuration file.

When To Use

Use when you need to run a custom build script, such as a specific bundler or transpiler, before Wrangler processes your code for deployment or local development.

Reference Files

FileContainsUse For
SKILL.mdEntry point: scope, routing table, and workflow.Start here.
docs/workers-wrangler-custom-builds-workflow-guide.mdDocumentation explaining how to configure custom build processes and the WRANGLER_COMMAND environment variable for Cloudflare Workers.Questions about documentation explaining how to configure custom build processes and the WRANGLERCOMMAND environment variable for Clo...
examples/workers-wrangler-custom-builds-cloudflare-workers-wrangler-custom-builds.textA configuration object defining the build command, current working directory, and watch directory for Cloudflare Workers custom builds.Exact payloads, commands, or snippets shown in A configuration object defining the build command, current working directory, and watch directory for Cloudflare Work...
examples/workers-wrangler-custom-builds-cloudflare-workers-wrangler-custom-builds-2.textA configuration example defining the build command, current working directory, and watch directory for Cloudflare Workers custom builds.Exact payloads, commands, or snippets shown in A configuration example defining the build command, current working directory, and watch directory for Cloudflare Wor...
examples/workers-wrangler-custom-builds-cloudflare-workers-wrangler-custom-build-.textA bash script template used to define conditional build logic for development and production environments in Cloudflare Workers custom builds.Exact payloads, commands, or snippets shown in A bash script template used to define conditional build logic for development and production environments in Cloudfla...

What This Skill Covers

  • Custom builds are a way for you to customize how your code is compiled, before being processed by Wrangler.
  • Main sections: Configure custom builds, WRANGLERCOMMAND environment variable.

Workflow

  1. Open the most relevant file under docs/ for the exact documented workflow and wording.
  2. Open schemas/ files for exact structured contracts.
  3. Open examples/ files for concrete requests, commands, snippets, and manifests.
  4. Do not add behavior or configuration that is not present in the attached source files.

Canonical source: https://developers.cloudflare.com/workers/wrangler/custom-builds