Delete file from node_modules

#1

Is it possible to delete a file from the node_modules?

and thanks! :slight_smile:

File renamed deleted a file!
#2

Hey @MoonBuster, welcome to the Glitch forum!

I’ve moved your post to its own topic, since it didn’t really have anything to do with the previous topic.

You can delete a file from node_modules, but that file will simply be replaced the next time Glitch installs your project’s dependencies. Can you tell us more about what you’re trying to accomplish so we can provide specific advice?

#3

it’s that when i make a file on a folder for example
if i delete that file and it’s folder
it will still be in the node_modules file why?

and thanks

#4

I’m definitely not understanding something, sorry! Can you provide a specific example?

#5

ok sorry!


this picture here shows that in the console it says that there is a folder named “website”
and that folder is a folder i made and then delete it for some reason
anyways!
my question here is that why is it still with my project’s files? :thinking:

#6

From what I can see here it looks like you removed the files from within the website folder but not the folder itself. Since there are no files it won’t show up in the file tree, but it still exists in your project’s local file system.

How does node_modules fit into this?

#7

i wrote node_modules mistakenly XD
because i was active on like 7 things at the same time so yea :slight_smile:

but ok is there any way to delete the folder? :thinking:

1 Like
#8

In your project’s console run rm -rf website and that should get rid of it.

#9

Thanks, man! :heart:

1 Like