Late, but I described how you can do it here . This works on AngularJS 1.6.x
Basically, you can run $parsers pipeline with $setViewValue() .
Below is a snippet of code that allows you to programmatically install ngModel on everything you like, by "grabbing" the $ parsers pipeline. This is done using closure.
Configure $ parser with closure as follows:
const hijack = {trigger: false; model: null}; modelCtrl.$parsers.push( val => { if (hijack.trigger){ hijack.trigger = false; return hijack.model; } else {
Then, to (re) install the model, you need to start the pipeline by changing $viewValue to modelCtrl.$setViewValue('newViewValue') . (Yes, it is true that the new view value must be different from the current value).
const $setModelValue = function(model){
source share