I have a controller that needs to get some info from a component. Each are getting created by angular through the dom. I understand that components update the models that are given to them which can be provided by the controller. What is the angular way to notify the controller about those changes in the component?
相关问题
- What means in Dart static type and why it differs
- Flutter : Prepare list data from http request
- How to schedule an alarm on specific time in Flutt
- MappedListIterable is not a SubType
- What is the difference between generics and dynami
相关文章
- Observatory server failed to start - Fails to crea
- Adding Shadows at the bottom of a container in flu
- Flutter. Check if a file exists before loading it
- Receive share file intents with Flutter
- Do stateless widgets dispose on their own?
- how to implement Alphabet scroll in flutter
- Flutter: Is it possible to format (bold, italicize
- Make Function parameter optional in custom widget
See docs
Also of interest:
To say that you want a controller to be notified about a change from a component isn't really the correct way to think about what is going on.
In the controller, some type of data model is represented and projected to a view using the current $scope of the controller. When a DOM element (component I'm assuming from your terminology) wants to update the model that the controller is providing, that model is bound via a directive (commonly ng-model) to a component. When that component changes the model, the data is updated automatically because of the directive and the data binding.