Skip to content
This repository has been archived by the owner on May 29, 2019. It is now read-only.

fix(typeahead): add support for ngModelOptions getterSetter #3865

Closed

Conversation

wesleycho
Copy link
Contributor

  • Add support for getterSetter with ngModelOptions

Fix can be seen in action in this Plunker.

This fixes #3823.

@pkarikh
Copy link

pkarikh commented Jun 30, 2015

Works for me! Thank you. :)

@lehresman
Copy link

This fixes the problem for me as well. Please merge this for 0.13.1. Thanks!

- Add support for getterSetter with ngModelOptions
@wesleycho wesleycho force-pushed the fix/typeahead-getter-setter branch from 7c27760 to 963ec0e Compare July 3, 2015 20:46
@chrisirhc
Copy link
Contributor

Argh, this feels like we're copying internal ngModel APIs to be able to replicate its functionality. Is there no other alternative?

@wesleycho
Copy link
Contributor Author

I don't like it either, but upon inspecting how ng-model implements it, this seems like how we have to do it - ideally the typeahead probably should be refactored since the whole $setModelValue is a bit of a hack.

@wesleycho wesleycho modified the milestones: 0.13.1 (npm), 0.13.2 (Performance) Jul 23, 2015
@wesleycho wesleycho modified the milestones: 0.13.2 (1.4 support), 0.13.3 (Performance) Aug 2, 2015
@wesleycho wesleycho modified the milestones: 0.13.3 (Fixes), 0.13.4 (Performance) Aug 9, 2015
@wesleycho
Copy link
Contributor Author

After discussing this a bit with some others on this, the opinion is that this is an ok change - IMO this is a weakness with the getterSetter API with ngModel in Angular itself.

@wesleycho wesleycho closed this in ccaa627 Aug 31, 2015
@wesleycho wesleycho deleted the fix/typeahead-getter-setter branch November 7, 2015 18:32
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Typeahead does not support ng-model-options="{getterSetter: true}"
4 participants