i was able to get by with a monorepo
i was able to get by with a monorepo with workers each in their own directory, with a single tsconfig.json and single package.json at root.
Code sharing is no problem and yes, dependencies aren’t as easy to track between each of the workers, but Wrangler anyway would bundle only whats required for each of the workers.
The way i see it, each worker has a separate wrangler.toml in its respective folders, and that is the more important/ separate manifest than package.json.
My one package.json has proliferated scripts for the 3 workers each with a -c /path/to/its/wrangler.toml but it works fairly well. Wrangler never has a hiccup in this system of a monorepo.
1 Reply
Thanks for this, that's interesting. Presumably this means deploying via CLI, though, not GH action? The latter would pull the entire repo into the Worker, I'd have thought.