-
Notifications
You must be signed in to change notification settings - Fork 6.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: remove the need for forRoot on material NgModules #2556
Conversation
Seeing some failures w/ AoT that don't quite make sense to me. Consulting w/ core team. |
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.
Typos and a question
@@ -88,3 +88,11 @@ export class ScrollDispatcher { | |||
} | |||
} | |||
|
|||
export const SCROLL_DISPATCHER_PROVIDER = { | |||
// If there is already an ScrollDispatcher available, use that. Otherwise, provide a new one. |
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.
Nit: an ScrollDispatcher
-> a ScrollDispatcher
@@ -56,3 +55,12 @@ export class ViewportRuler { | |||
return {top, left}; | |||
} | |||
} | |||
|
|||
export const VIEWPORT_RULER_PROVIDER = { | |||
// If there is already an ViewportRuler available, use that. Otherwise, provide a new one. |
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.
Nit: an ViewportRuler
-> a ViewportRuler
@@ -62,3 +63,15 @@ export class LiveAnnouncer { | |||
} | |||
|
|||
} | |||
|
|||
export const LIVE_ANNOUNCER_PROVIDER = { | |||
// If there is already an LiveAnnouncer available, use that. Otherwise, provide a new one. |
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.
Nit: an LiveAnnouncer
-> a LiveAnnouncer
@@ -167,10 +166,11 @@ export class MdAnchor extends MdButton { | |||
declarations: [MdButton, MdAnchor], |
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.
Do you need to provide VIEWPORT_RULER_PROVIDER up here since you removed below? Same with checkbox.
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.
Nope, it is not included by way of MdRippleModule
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.
Cool, just double-checking
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
e8dc761
to
147a077
Compare
Also cc FYI @devversion @crisbeto @EladBezalel |
@jelbourn looks reasonable. please file an issue @ angular/angular if you haven't yet. Let's see if the core can help with this pattern as it looks better to me from the user perspective than the |
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, this should close #1150 as well.
@devversion yes, it caught some real errors |
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. |
useFactory
provider to get the ancestor and provide that if it existscc @IgorMinar can you provide thoughts on this?
cc FYI @josephperrott @mmalerba @andrewseguin @tinayuangao