I'm using angularJS. I have a few <select>
elements on my page, each with its own ng-change
, for example:
<select id="hairColorComponent" ng-model="hairColor"
ng-options="option.name for option in hairColorData"
ng-change="updateUserData()">
I want to be able to determine which DOM element got updated from within the updateUserData
function, without having to manually specify it as a parameter for each ng-change
attribute.
Is there an event
, or caller
or something similar that I can use within the context of updateUserData
?
Hopefully something like ng-change="updateUserData(caller)"