Solucionado (ver solução)
Solucionado
(ver solução)
2
respostas

Erro

Olá, está dando erro. Aparece isso no meu prompt


Microsoft Windows [versão 10.0.16299.192] (c) 2017 Microsoft Corporation. Todos os direitos reservados.

C:\Users\User>npm install npm WARN saveError ENOENT: no such file or directory, open 'C:\Users\User\package.json' npm WARN enoent ENOENT: no such file or directory, open 'C:\Users\User\package.json' npm WARN User No description npm WARN User No repository field. npm WARN User No README data npm WARN User No license field.

up to date in 0.059s

C:\Users\User>npm start npm ERR! path C:\Users\User\package.json npm ERR! code ENOENT npm ERR! errno -4058 npm ERR! syscall open npm ERR! enoent ENOENT: no such file or directory, open 'C:\Users\User\package.json' npm ERR! enoent This is related to npm not being able to find a file. npm ERR! enoent

npm ERR! A complete log of this run can be found in: npm ERR! C:\Users\User\AppData\Roaming\npm-cache_logs\2018-01-13T20_27_13_763Z-debug.log

2 respostas
solução!

Giovani Urnau, pelo que parece o seu terminal (prompt) esta aberto no diretorio errado, e ao rodar o comando:

npm install

não é encontrado o arquivo package.json, que contem os pacotes a serem instalados.

use o comando cd nomePasta para navegar no diretorio onde se encontra o projeto.

uso MAC, o meu erro é esse:

alurapic@1.0.0 start /Users/marciojusto/Desenvolvimento/angular/alurapic node server.js

module.js:540 throw err; ^

Error: Cannot find module 'express' at Function.Module._resolveFilename (module.js:538:15) at Function.Module._load (module.js:468:25) at Module.require (module.js:587:17) at require (internal/module.js:11:18) at Object. (/Users/marciojusto/Desenvolvimento/angular/alurapic/config/express.js:1:77) at Module._compile (module.js:643:30) at Object.Module._extensions..js (module.js:654:10) at Module.load (module.js:556:32) at tryModuleLoad (module.js:499:12) at Function.Module._load (module.js:491:3) npm ERR! code ELIFECYCLE npm ERR! errno 1 npm ERR! alurapic@1.0.0 start: node server.js npm ERR! Exit status 1 npm ERR! npm ERR! Failed at the alurapic@1.0.0 start script. npm ERR! This is probably not a problem with npm. There is likely additional logging output above. npm WARN Local package.json exists, but node_modules missing, did you mean to install?

npm ERR! A complete log of this run can be found in: npm ERR! /Users/marciojusto/.npm/_logs/2018-01-21T15_03_43_818Z-debug.log