question-mark
Stuck on an issue?

Lightrun Answers was designed to reduce the constant googling that comes with debugging 3rd party libraries. It collects links to all the places you might be looking at while hunting down a tough bug.

And, if you’re still stuck at the end, we’re happy to hop on a call to see how we can help out.

Working with static assets (images) in v3

See original GitHub issue

Before I used my images as:

![](images/something.png)

<img src="images/something.png" />

While keeping a top level images folder in my project and that worked fine. With the move to v3 this stopped working. I dug a bit into Gatsby and tried moving my images folder into a static folder, but that did not work.

How can we use static resources, such as images? Is there still a folder being served?

Issue Analytics

  • State:open
  • Created 4 years ago
  • Reactions:9
  • Comments:9 (5 by maintainers)

github_iconTop GitHub Comments

6reactions
HoverBaumcommented, Aug 7, 2019

Can confirm that the import way works but requires a reload of the dev server every time you add an image 😞

I published a minimal reproduction repo: https://github.com/HoverBaum/bug-mdx-deck-401

4reactions
alpinegizmocommented, Jul 19, 2019

The webpack workaround appears to have the drawback that I have to restart the dev server every time I add an image. That’s unacceptable; any way to make this dynamic?

Read more comments on GitHub >

github_iconTop Results From Across the Web

Static Asset Handling - Vite
Common image, media, and font filetypes are detected as assets automatically. You can extend the internal list using the assetsInclude option.
Read more >
Using static module assets | Apostrophe 3 Documentation
While developers can place static files in the top-level /public folder of the project, which allows a file like /public/images/bg.png to be ...
Read more >
Using Static Asset Files in Angular | mobiarch
Similar smart features exist for other static asset files like images. In today's article I will explore this area.
Read more >
Static Files & Images | Django Framework (3.0) Crash Course ...
Static Files & Images | Django Framework ( 3.0 ) Crash Course Tutorials (pt 4).
Read more >
How to manage static files (e.g. images, JavaScript, CSS)
Websites generally need to serve additional files such as images, JavaScript, or CSS. In Django, we refer to these files as “static files”....
Read more >

github_iconTop Related Medium Post

No results found

github_iconTop Related StackOverflow Question

No results found

github_iconTroubleshoot Live Code

Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free

github_iconTop Related Reddit Thread

No results found

github_iconTop Related Hackernoon Post

No results found

github_iconTop Related Tweet

No results found

github_iconTop Related Dev.to Post

No results found

github_iconTop Related Hashnode Post

No results found