Here is the image:
<img src="src/img/image.svg" alt="" />
The folder structure is like so:
src
-img
-components
...etc
Yet the image shows nothing and I get a 404 error in the console?
Gatsby在项目根目录的static
文件夹中查找静态资产 ,因此,如果您希望示例图片可以工作,并且不想使用,请确保图片位于static/src/img/image.svg
Webpack模块系统。
The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.