how to display image through online URL path in react ,if I try to do that code its not working
import React from 'react';
export default function Dropdown() {
return (
<div>
<img alt="picture"src="https://pixabay.com/photos/strawberries-fruit-season-eating-3359755/"
height={200} width={200}/>
</div>
);
}
>Solution :
It’ just that your source image is wrong. Try this:
import React from 'react';
export default function Dropdown() {
return (
<div>
<img alt="picture" src="https://cdn.pixabay.com/photo/2018/04/29/11/54/strawberries-3359755_960_720.jpg" height={200} width={200}/>
</div>
);
}