Skip to content

initCallback is never called if iframe doesn't need to be resized yet #213

Closed
@lostincomputer

Description

@lostincomputer

initCallback is not called if the page doesn't need to be resized initially (isSizeChangeDetected returns false).

Here is a sample page to reproduce the issue with the default iframe-resizer settings

<body style="margin: 0; padding: 0">
<div id="content" style="height: 1px; background-color: red"></div>
<script>
$(function() {
   setTimeout(function() {
    $("#content").height(50);
   }, 1000);
});
</script>
</body>

My workaround right now is to use resizedCallback.

Metadata

Metadata

Assignees

No one assigned

    Labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions