Skip to main content

Given below is how I’ve coded a simple import of a png image and rendering it inside my Figma plugin:


const img = require('../../assets/hola.png');

const Welcome = () => (
<>
<img src={img} height={42} width={42} alt="Wordtract"/>
</>
)

However, the following is the output:


Screenshot 2022-04-17 at 2.53.10 AM


There aren’t any console errors. Please help me out solving this. Cheers!


Reply