Luane
Luane

Reputation: 91

How to load local static assets or sprite in scratch-gui?

In the 'src/components/library-item/library-item.jsx' it is loading assets from remote url:

const iconURL = iconMd5 ?
https://cdn.assets.scratch.mit.edu/internalapi/asset/${iconMd5}/get/ :
this.props.iconRawURL;

but I want to load my local assets, so I modified it to:

const iconURL = iconMd5 ? ./static/assets/${iconMd5} : this.props.iconRawURL;

but now, I don't know how to download the assets to my project...

Someone had same issue (https://github.com/scratchfoundation/scratch-gui/issues/4998), I checked the scratch-desktop but was not able to figure out how to solve it...

I appreciate any help 🙇‍♀️

Upvotes: 0

Views: 66

Answers (0)

Related Questions