and welcome to NodeJS. Hope this little issue hasn't deterred you, and hopefully by now you have overcome this challenge and moved on your NodeJS journey. But in spirit of sharing knowledge, here is what had happened.
As your npm install
script indicated, you have not provided description
and repository
fields, and you don't have a README.md
file.
The easiest way to create a new package.json
is to run the npm init command
.
npm init --yes
Here is a sample package.json file to get you started. Best of luck!!
{
"name": "my_package",
"description": "Awesome NodeJS project.",
"version": "1.0.0",
"main": "index.js",
"scripts": {
"test": "echo \"Error: no test specified\" && exit 1"
},
"repository": {
"type": "git",
"url": "https://github.com/ashleygwilliams/my_package.git"
},
"keywords": [],
"author": "",
"license": "ISC",
"bugs": {
"url": "https://github.com/ashleygwilliams/my_package/issues"
},
"homepage": "https://github.com/ashleygwilliams/my_package"
}