Relative Content

Tag Archive for reactjsnpmvite

Problem with using box-ui-elements and ContentPreview as a React component

The bounty expires in 5 days. Answers to this question are eligible for a +50 reputation bounty. DisastrousEcho is looking for an answer from a reputable source. I’, relatively new in React and I’ve just started working with Box integration. I managed to use Box by referencing the versions available on Box’s CDN (https://github.com/box/box-content-preview?tab=readme-ov-file#including-preview-as-a-library). But, […]

New Vite Project not installing node modules after “npm i”

I am in the process of creating a new react project with vite and whenever I run “npm i” inside the project the node modules and package lock are not created. I have vite and node installed and updated globally. I am on a windows machine and when I also “npm run dev” I get this error:

New Vite Project not installing node modules after “npm i”

I am in the process of creating a new react project with vite and whenever I run “npm i” inside the project the node modules and package lock are not created. I have vite and node installed and updated globally. I am on a windows machine and when I also “npm run dev” I get this error:

command npm create vite@latest throwing me an error. How to resolve this?

projectsnew-app> npm create vite@latest
npm ERR! code ECONNREFUSED
npm ERR! syscall connect
npm ERR! errno ECONNREFUSED
npm ERR! FetchError: request to https://registry.npmjs.org/create-vite failed, reason: connect ECONNREFUSED ::1:5173
npm ERR! at ClientRequest. (C:UsersRAVI BARASKARAppDataRoamingnpmnode_modulesnpmnode_modulesminipass-fetchlibindex.js:130:14)
npm ERR! at ClientRequest.emit (node:events:514:28)
npm ERR! at _destroy (node:_http_client:882:13)
npm ERR! at onSocketNT (node:_http_client:902:5)
npm ERR! at process.processTicksAndRejections (node:internal/process/task_queues:83:21)
npm ERR! FetchError: request to https://registry.npmjs.org/create-vite failed, reason: connect ECONNREFUSED ::1:5173
npm ERR! at ClientRequest. (C:UsersRAVI BARASKARAppDataRoamingnpmnode_modulesnpmnode_modulesminipass-fetchlibindex.js:130:14)
npm ERR! at ClientRequest.emit (node:events:514:28)
npm ERR! at _destroy (node:_http_client:882:13)
npm ERR! at onSocketNT (node:_http_client:902:5)
npm ERR! at process.processTicksAndRejections (node:internal/process/task_queues:83:21) {
npm ERR! code: ‘ECONNREFUSED’,
npm ERR! errno: ‘ECONNREFUSED’,
npm ERR! syscall: ‘connect’,
npm ERR! address: ‘::1’,
npm ERR! port: 5173,
npm ERR! type: ‘system’
npm ERR! }
npm ERR!
npm ERR! If you are behind a proxy, please make sure that the
npm ERR! ‘proxy’ config is set properly. See: ‘npm help config’