Example using img tag with h function with local icons

I’m using the h function in the UI Rename Artboards examples and I can’t seem to show images in the UI in my plugin directory.

Here is what I have so far:

var label;
var row =
	h("div", { class: "row", alignItems:"center", style: { border: "1px solid blue" } },
		label = h("span", { style: { width: leftWidth, border: "1px solid red" } }, "Row:"),
		h("img", { src:"icons/Test Icon.png", width:"10", height:"10", style:{border: "1px solid green", width:"20px", height:"20px"}}), 
		h("span", { style: {  border: "1px solid black"} }, "test" )

What’s your plugin structure look like (as in, where does Test Icon.png live?)

False alarm. The icons were saved to my test plugin folder. I moved them and they are now showing up. :slight_smile:

1 Like