iframeiframe-resizer

How can I change the options that `iframe-resizer` is using?


I have an iframe on my page and I'm using iframe-resizer to have it resize to match its content. I'm using the maxHeight option to limit its size. This is working fine.

However, sometimes I want to change the value of maxHeight, in response to actions in the parent page.

I've tried calling iframeResizer(newOptions, myIframe) but this doesn't seem to change anything - the old options are still in effect.

Is there a way I can change the options on the fly?


Solution

  • The options you pass to iframe-resizer are not changeable after it has been setup.