We have some custom validation directives that we'd like to be able to use on md-autocomplete, but can't, because it doesn't use ng-model (and the wrapped <md-input-container> has its own ng-model).
Great feature for PR from community contributor.
@calebegg What item you want to access from the ngModelController? The selected item or just the search text?
For our use case, we want the search text. Though, I know other people want the selected item so they can mark it as invalid if there's no selected item.
For our use case we would like to access the selected item as @calebegg said just to ensure an item was selected from the list instead of validating against the presence of search text.
Okay, I just think about the search text too. We should provide both possibilities. But in first, what do you think about mirroring a ngModel, which can be accessed from the custom directives?
Mirroring the ngModel for use with custom directives would be fine
Great to see this is being discussed!
@DevVersion what does mirroring the ngModel mean? Would it support the standard <md-autocomplete name=someName ng-model=$ctrl.someProp approach (see #7910)?