V
V
virtualhero2017-05-03 21:35:11
Node.js
virtualhero, 2017-05-03 21:35:11

NodeJS NPM: error when package.json is missing?

I’m learning NodeJS, now I’m tormenting my brains with npm and I can’t understand why in all the docks and video lessons that I saw package.json no one creates, but just download modules successfully and without errors, but it gives me: no such file or directory, open 'C:\Users\smoot\Desktop\package.json'
Why is that? what am I doing wrong?

Answer the question

In order to leave comments, you need to log in

1 answer(s)
D
Denis Ineshin, 2017-05-03
@virtualhero

Because the module itself doesn't make sense.
It should be part of the project and nothing else.
Before you start, use npm init for example.

Didn't find what you were looking for?

Ask your question

Ask a Question

731 491 924 answers to any question