javascript - event for change of value via developer tools -
is there event triggered when change value of input using developer tools?.
i have tried using change()
, blur()
, focus()
. these events not triggered if change values via developer tools.
it seems mutationobserver-api not possible. if manipulate value of input via console directly, mutation doesn't trigger.
the other possibility tried wasn't helpful either: developer-tools opened, right-click on input , choosing "break on -> attributes change". isn't working, too.
i'll think little - right seems it's not working easily...
first answer:
you should mutationobserver-api if not trying support old browsers. taking example there starting point, try this:
// select target node var target = document.queryselector('#your-input'); function mutationcallback(mutation) { /* logic here */ } // create observer instance var observer = new mutationobserver(function(mutations) { mutations.foreach(mutationcallback); }); // configuration of observer: var config = { attributes: true, childlist: true }; // pass in target node, observer options observer.observe(target, config);
Comments
Post a Comment