How to add an eventListener to an Object in javascript which will fire when object is manipulated?

You're mixing up JavaScript programming with DOM programming. Events are purely a DOM concept. JS objects do not support event handlers.

You're mixing up JavaScript programming with DOM programming. Events are purely a DOM concept. JS objects do not support event handlers.

The only way to do it is to create getters and setters. There are ways to do this with special properties, but unfortunately, browser support is a bit maybe. The other way to do it is using explicit methods and private variables.

This is possible but a little complex.

Thanks for that. – KakambaWeb Oct 11 '10 at 3:02.

I cant really gove you an answer,but what I can give you is a way to a solution, that is you have to find the anglde that you relate to or peaks your interest. A good paper is one that people get drawn into because it reaches them ln some way.As for me WW11 to me, I think of the holocaust and the effect it had on the survivors, their families and those who stood by and did nothing until it was too late.

Related Questions