angular icon indicating copy to clipboard operation
angular copied to clipboard

refactor(router): Move navigation transition logic into a separate file

Open atscott opened this issue 3 years ago • 1 comments

This commit extracts the Router's navigation "transitions" to a separate file. The goal here is twofold:

  • Separate the Router's logic into more manageable chunks. Rather than having to always edit a 1000+ line file, this separates different pieces into smaller, more focused files
  • More importantly, this sets the groundwork for separating the Router state from the individual navigation transition. That is, it would be good for the rxjs pipeline to not modify the Router state but only keep track of its own intermediate stages and emit outwards during important events. The Router can subscribe to those events and make updates to its state. This would theoretically allow us to swap those implementations independently. That is, the Router's state management can be changed without changing the transition handling and vice-versa.

Reviewer note: This change is split up into two commits. The first copies the router.ts file to a new file without changes. The second commit updates the code. This is done to better show the diff in the navigation_transitions.ts file. If only git supported file branching hints.

atscott avatar Nov 16 '22 21:11 atscott

Caretaker Note: Please ignore the google-internal-tests status. checkTests passed after rerun but status is not updating

atscott avatar Nov 18 '22 00:11 atscott

@atscott Looks like this needs a rebase also.

dylhunn avatar Nov 22 '22 19:11 dylhunn

Note: retargeting to minor and will have to create a separate PR for patch. There was a feature merged to minor that has diverged the branches.

atscott avatar Nov 22 '22 22:11 atscott

Caretaker Note: Please ignore the google-internal-tests status. Tests are failing at HEAD internally. deflaking does not resolve this type of failure.

atscott avatar Nov 22 '22 23:11 atscott

This PR was merged into the repository by commit 3c6a439a6fec6c921e08bde583a457953424b4bc.

dylhunn avatar Nov 23 '22 00:11 dylhunn

This issue has been automatically locked due to inactivity. Please file a new issue if you are encountering a similar or related problem.

Read more about our automatic conversation locking policy.

This action has been performed automatically by a bot.