Skip to content

refactor(@angular/build): normalize library builder paths to POSIX format - #34342

Merged
alan-agius4 merged 3 commits into
angular:mainfrom
alan-agius4:library-posix-paths
Oct 14, 2026
Merged

alan-agius4 merged 3 commits into
angular:mainfrom
alan-agius4:library-posix-paths

Conversation

@alan-agius4

Copy link
Copy Markdown
Collaborator

Normalize paths at option and compilation boundaries in the library builder to POSIX format and update TSDoc comments across the library builder pipeline.

Related to #34340.

…rmat

Normalize paths at option and compilation boundaries in the library builder to POSIX format and update TSDoc comments across the library builder pipeline.

@gemini-code-assist gemini-code-assist Bot left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Code Review

This pull request refactors the library builder to normalize all file and directory paths to POSIX format early in the options normalization phase, allowing downstream processes to assume POSIX paths and removing redundant path conversions. Feedback on these changes suggests optimizing the asset matching logic in assets.ts by precomputing POSIX input prefixes and using efficient string operations (startsWith and slice) instead of calling path.posix.relative inside nested loops, which could introduce performance bottlenecks during incremental builds.

Comment thread packages/angular/build/src/builders/library/pipeline/assets.ts
Comment thread packages/angular/build/src/builders/library/pipeline/assets.ts
@alan-agius4 alan-agius4 added action: review The PR is still awaiting reviews from at least one requested reviewer target: minor This PR is targeted for the next minor release labels Oct 14, 2026
@alan-agius4
alan-agius4 requested a review from clydin October 14, 2026 10:12
@alan-agius4 alan-agius4 added action: merge The PR is ready for merge by the caretaker and removed action: review The PR is still awaiting reviews from at least one requested reviewer labels Oct 14, 2026
@alan-agius4
alan-agius4 merged commit a3b6d48 into angular:main Oct 14, 2026
40 checks passed
@alan-agius4
alan-agius4 deleted the library-posix-paths branch October 14, 2026 16:57
@alan-agius4

Copy link
Copy Markdown
Collaborator Author

This PR was merged into the repository. The changes were merged into the following branches:

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

action: merge The PR is ready for merge by the caretaker area: @angular/build target: minor This PR is targeted for the next minor release

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants