Hi, community
I’ve set up an app with the components.declare_component. Here is the snippet:
import os
import streamlit.components.v1 as components
_RELEASE = True
if not _RELEASE:
_component_func = components.declare_component(
"root_component",
url="http://localhost:5300",
)
else:
parent_dir = os.path.dirname(os.path.abspath(__file__))
_component_func = components.declare_component(
"root_component",
url="https://resume-matcher.netlify.app/",
)
def root_component(data, key=None) -> dict[str, str]:
component_value = _component_func(data=data, key=key, default=0)
return component_value
As you can see, the url is used for declaration, but it doesn’t show up in the browser properly. The iframe loads when I open the dev tools on the Chrome browser.
How can I resolve the issue? Thanks.
Best,