Nathan Ortega
Nathan Ortega

Reputation: 658

Unhandled rejection Error: ENOENT when creating a Nativescript Project

I've been following the Nativescript tutorial here, but I've been having issues creating the tutorial project. I ran tns doctor which confirmed that my environment was set up correctly, yet I'm still getting an obscure error when attempting to create a project. Any help is appreciated

Here are the two errors I'm getting:

1.) Unhandled rejection Error: ENOENT: no such file or directory, stat 'C:\Users\Nate\AppData\Roaming\npm-cache\_cacache\content-v2\sha512\ee\97\12f9f20988b7890bc5d892b6 f3d12771c88f9ede06c3361e81ad827bea4ddd31e5738f7723ea129e5bf110019f28f9d8d5b7670e3b68d395893e88258282'

2.) Command npm.cmd install [email protected] --silent --save-exact --save failed with exit code 1

Here's the screenshot (for more context) enter image description here

Upvotes: 0

Views: 1034

Answers (2)

Rahul Tiwari
Rahul Tiwari

Reputation: 372

You can try these steps:

npm uninstall nativescript 
npm cache clean
npm install -g nativescript

Then

tns create HelloWorld --template nativescript-template-ng-tutorial

Upvotes: 0

Jonathan
Jonathan

Reputation: 592

It looks like something might be corrupt in your npm cache. You could try:

npm cache clean

or

npm cache verify

I believe that verify is only in npm 5+.

Upvotes: 2

Related Questions