✊🏿 Black Lives Matter. Please consider donating to Black Girls Code today.
⚡️ Concerned about the grid? Kyle Baranko teaches how to predicting peak loads using XGBoost. Register for the August webinar!

Iframe and dbc.Tabs, CORDS problems with Netron integration?

Hi guys,

I’m building an interface for a neural network with Dash.
I used the dbc.Tabs component to split the page into multiple tabs.

I inserted the html.Iframe tag in a tab to link the application with Netron (https://github.com/lutzroeder/netron).

The problem I encounter happens when I load / reload the page. If the active tab is not the one where the html.Iframe is contained, this happens:

But, if i set as active tab the tab where the html.Iframe is located, everything works:

This is the part of the code where I put the iframe:

 dbc.Tab(html.Div(html.Iframe(src="http://localhost:8080", width='100%', height='780px')),
                            label="Network architecture", tab_id="network_arch", className="mt-2"),

I found this answer on git: https://github.com/lutzroeder/netron/issues/302
But I can’t figure out if I should use CORDS (from flask_cords ??) and how to activate them in a Dash application.

Also, in the browser’s console i have this error:
[Error: attribute transform: Expected number, “translate(undefined,undefi…”]

I’m new on Dash and i don’t know where the problem might be.
Thank you very much for helping!