Skip to content

The image cannot be displayed due to an incorrect path. #38

@IsmailDr13f

Description

@IsmailDr13f

When using the Card component from MUI within the streamlit-elements framework, I encounter an issue where images fail to render if I pass either a complete or relative path to the image attribute. Upon inspection, I found that the image path is incorrectly resolved: the tool automatically concatenates the path with the internal static directory (frontend/build) of the original streamlit-elements project. As a result, the actual file path becomes invalid, and the image cannot be displayed.
This behavior poses a critical limitation: if I manually place image files inside the frontend/build directory to make them work, these files are at risk of being lost whenever the streamlit-elements package is updated or rebuilt, as this directory is managed internally and not meant for persistent custom assets.

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions