Saving images in my project?

javascript

#1

When I use the fs module to download images to my project (fs.createWriteStream), they don’t appear instantly. I can do “dir” on the console and see the images there but not on the project editor. After some time passes, like 30 minutes or so, the images suddenly appear there. Why does this happen? Is there a way to download the images and make them appear on the editor instantly? Thanks.


#2

Here’s my code, if it helps.


#3

Hey @MQRLZ, welcome to the Glitch Forums!

You files created or edited by the backend (either by your code or by activity in the console like wget) don’t automatically sync with the editor. You have to run refresh in the console to get those changes to show up, or wait a bit, as you’ve noticed.

There’s a (very) brief description of this in this help article.

Hope this helps!


#4

I see. Thank you for your answer!