Skip to content

Add images to Assets? #411

@karkkant

Description

@karkkant

Say, if I want to do something like this to display an arbitrary icon in component:
<img src={'/images/' + this.props.item.someType + '.png'} />

It doesn't work out-of-the-box since the images would have to be served from /public folder. I could work around this by moving images folder to public/assets, and change build script so that bundles and rimraf would target a resource subfolder... But is there a better way to do this? If not, maybe it's something that could be enhanced in template?

Metadata

Metadata

Assignees

No one assigned

    Labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions