iframeAutoSize

Type:Function
Status:stable
Since:1.0.0
Platform:js
@blackbyte.sugar.js.dom.iframe

This function allows you to resize an iframe to fit its content.

Params

  1. $iframe*-HTMLElement

    The iframe element to resize

  2. settings{}TIFrameAutoSizeSettings

    Some settings to configure your iframe auto size

Example

import { iframeAutoSize } from '@blackbyte/sugar/dom';
iframeAutoSize($iframe);

Settings

  1. widthtrueBoolean

    Specify if you want to resize the width of the iframe

  2. heighttrueBoolean

    Specify if you want to resize the height of the iframe

Todo

  • testsnormal