I’m revisiting workers after a short break. I noticed that currently esbuild
is used to get things bundled up. I followed the bundle
function workers-sdk/bundle.ts at 68ba49a8c5bde2e9847e9599d71b9a501866c54b · cloudflare/workers-sdk · GitHub and failed to find a way to augment and expand loaders. I see COMMON_ESBUILD_OPTIONS
and one parameter that can be used, but there’s no mention of altering it with a config. Is there a way to make it happen without running a custom esbuild?
Ok, I just followed the bundling docs and it’s there. Configuration · Cloudflare Workers docs and with the rule for data
rules = [
{ type = "Data", globs = ["**/*.data"], fallthrough = true }
]
it works just fine!