skip to Main Content

During installing

, the following error occurred. Please help me.enter image description here

I thought there was a problem after installing it at first, so I was going to delete it and reinstall it, but it didn’t erase well. As I tried to download it again in that situation, I had a problem and it led to the same result as now. What should I do in this situation?

3

Answers


  1. Permission denied.

    what’s your commnad?

    are you using ‘-g’ ?

    Login or Signup to reply.
  2. please use

    sudo

    before you install with -g

    it will allows you to get the permission

    Login or Signup to reply.
  3. If you are on Windows, did you try your command line tool in admin mode to execute npm i -g create-react-app ?

    Admin mode allows the permission to create files on protected folders and it can avoid any permission issues.

    If your npm version is 5.2+, you can execute Node packages without -g which means you do not need global package clogging.

    npx create-react-app my-app
    cd my-app
    npm start
    

    Furthermore, if you use npx that means you are using the latest version of create-react-app no manual upgrades needed.

    For your reference:

    How to create a React app directly in the current folder

    https://create-react-app.dev/docs/getting-started/

    Login or Signup to reply.
Please signup or login to give your own answer.
Back To Top
Search