scaffold: document monorepo self-contained deploy; bundling optional - #1645
Open
Nathan (nturinski) wants to merge 2 commits into
Open
scaffold: document monorepo self-contained deploy; bundling optional#1645Nathan (nturinski) wants to merge 2 commits into
Nathan (nturinski) wants to merge 2 commits into
Conversation
…ional Keep the idiomatic modular per-file + glob-main Functions layout as the default. Fix the monorepo deployment failures at the deployment layer instead of switching to bundling: - Preferred shared fix: import shared via relative paths so tsc compiles it into the service dist (no workspace-package runtime dependency to resolve in a per-service deploy). - Resolve hoisted third-party deps with a service-level production install. - Document esbuild --packages=external single-file bundling as an OPTIONAL cold-start/single-artifact optimization, not the default.
Contributor
There was a problem hiding this comment.
Pull request overview
Updates the TypeScript runtime and scaffold agent guidance to keep Azure Functions services deployable as independent artifacts in monorepo/npm-workspaces setups, while keeping the default modular per-function-file layout and positioning bundling as optional.
Changes:
- Document monorepo/npm-workspaces deployment pitfalls and the preferred “self-contained service” approach (compile shared code into service output + handle hoisted deps).
- Clarify that single-file bundling (esbuild
--packages=external) is an opt-in optimization rather than the default scaffold layout. - Extend scaffold rules to include monorepo-specific deployment guidance and cross-workspace dependency handling.
Reviewed changes
Copilot reviewed 2 out of 2 changed files in this pull request and generated 1 comment.
| File | Description |
|---|---|
| resources/agents/shared-references/runtimes/typescript.md | Adds monorepo/workspaces deployment guidance and optional bundling notes to the TypeScript Functions deployment contract section. |
| resources/agents/azure-project-scaffold/instructions.md | Updates scaffold rule #13 to include monorepo self-contained deploy guidance and notes bundling is optional. |
💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.
Co-authored-by: Copilot Autofix powered by AI <175728472+Copilot@users.noreply.github.com>
Matthew Fisher (MicroFish91)
approved these changes
Aug 5, 2026
Megan Mott (motm32)
approved these changes
Aug 6, 2026
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Keep the idiomatic modular per-file + glob-main Functions layout as the default. Fix the monorepo deployment failures at the deployment layer instead of switching to bundling:
Preferred shared fix: import shared via relative paths so tsc compiles it into the service dist (no workspace-package runtime dependency to resolve in a per-service deploy).
Resolve hoisted third-party deps with a service-level production install.
Document esbuild --packages=external single-file bundling as an OPTIONAL cold-start/single-artifact optimization, not the default.