The iFrame is a sandboxed web page, it can be though5 of as an entire isolated standalone website that is loading inside the surrounding application.
Benefits of the iFrame
- The iFrame is an isolated environment. There will be no unexpected interactions or clashing between the application and the embedded dashboard because they are completely separate.
- Potential performance benefits - the loading of the iFrame and the surrounding application happen separately and one after the other. This means the iFrame should not impact the load time of the surrounding application.
Limitations of the iFrame:
- URL parameters in the browser can not be read directly from the iFrame and must be pushed into the iFrame url.
- URL relative paths are not accessable by the iFrame to be used for link formatting in the dashboard.
The web component is essentially a piece of code that will render inside the context of the surrounding application.
Benefits of the web component option:
- The web component lives in the same JS environment as the surrounding application. This means Explo supports event listeners via the web component. It also reads in URL params from the browser, and can pull in the URL relatives into the dashboard.
Limitations of the web component:
- There can be unexpected style clashing or loading issues as a result of one entire application’s code being loaded inside another application’s code.