Reputation: 45263
I'm struggling to learn all the strange JavaScript front-end tools. I'm a Microsoft guy so I'm used to being very highly-productive at the expense of knowing cool JavaScript tools or rocking a hipster beard.
I think I need to initialize NPM in my project with npm init
but its asking questions with single words and I haven't the faintest clue what to respond, the docs don't even mention the questions.
https://docs.npmjs.com/cli/init
So what do I put for name:
and version:
and any others that might be asked next?
Thanks!!
Upvotes: 3
Views: 2083
Reputation: 1497
npm init
is for creating a new package.json with npm.
npm install
is for installing all dependencies.
The question is, why do you think you need to npm init
- when you do not know which name your project has.
If you want to create a new project, add the name of the project and the version - for example 0.0.1
. Use semantic versioning for this, see http://semver.org/ .
The name is the name of your project. The version is the version of your project and if its a private app, then you can just put 1.0.0 in and leave it; its more for libraries you may be intending to add to a shared package repository.
Upvotes: 3