-
Notifications
You must be signed in to change notification settings - Fork 24.8k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
feat(migrations): Migration to remove Router
guard and resolver interfaces
#49337
Conversation
d5ff561
to
5a3d5ce
Compare
27e67ba
to
2ce08ae
Compare
2ce08ae
to
e96e6e3
Compare
packages/core/schematics/migrations/guard-and-resolve-interfaces/util.ts
Outdated
Show resolved
Hide resolved
packages/core/schematics/migrations/guard-and-resolve-interfaces/util.ts
Show resolved
Hide resolved
0b855f8
to
956a4ea
Compare
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
LGTM with some optional comments that can be ignored.
packages/core/schematics/migrations/guard-and-resolve-interfaces/util.ts
Show resolved
Hide resolved
packages/core/schematics/migrations/guard-and-resolve-interfaces/util.ts
Outdated
Show resolved
Hide resolved
packages/core/schematics/test/guard_and_resolve_interfaces_spec.ts
Outdated
Show resolved
Hide resolved
48cef5a
to
800f091
Compare
caretaker note: schematics require manual patching of internal build files |
…erfaces The class-based guard and resolver interfaces are deprecated. The `Router` types only support functional guards definitions. Classes can still be used as the underlying implementation of functional guards and resolvers but there will not be an interface requiring a specific structure for those classes. There are also helper functions like `mapToCanActivate` that allow converting the existing class-based guards directly to functional guards at the route definition. This will be done in a separate migration.
800f091
to
a487b05
Compare
This PR was merged into the repository by commit 5e5dac2. |
This issue has been automatically locked due to inactivity. Read more about our automatic conversation locking policy. This action has been performed automatically by a bot. |
The class-based guard and resolver interfaces are deprecated. The
Router
types only support functional guards definitions. Classes can still be used as the underlying implementation of functional guards and resolvers but there will not be an interface requiring a specific structure for those classes.There are also helper functions like
mapToCanActivate
that allow converting the existing class-based guards directly to functional guards at the route definition. This will be done in a separate migration.