Monitor dom element attribute changes?
I have a <div> container whose size varies based on it's content. This content is loaded dynamically via ajax while the user is interacting with page and also based on screen size (for example, resize of the window will affect the content height). There's a sidebar which is using the affix plugin positioned at the left of my main container.
I want to check if the height of the sidebar is bigger than the content panel and based on that, set affix plugin or unset it!
I tried attrchange plugin but that's not exactly what I'm looking for because i never set an explicity attribute value to the element that I'm trying to monitor. The element height varies based on it's content which doesn't trigger any change event!!
Do I really need to be polling my element to check if there's any change on it's height?
The implemention seems to use a settimeout to watch the attribute change