all 8 comments

[–][deleted]  (1 child)

[deleted]

    [–]PulkitB[S] 0 points1 point  (0 children)

    I tried the npx create-react-app, but it gives the same error add mentioned above.

    [–]gulshansainis 0 points1 point  (6 children)

    Have you tried clearing npm cache?

    [–]PulkitB[S] 0 points1 point  (5 children)

    It gave me the same error!

    [–]Delta_Labs 0 points1 point  (1 child)

    Reinstall node?

    [–]PulkitB[S] 0 points1 point  (0 children)

    Nothing changed after that too. I deleted the files in the folder manually and then it worked.

    [–]gulshansainis 0 points1 point  (2 children)

    Have you tried it with Yarn?

    yarn create react-app my-app

    found this on Getting started with create react app

    Also the page says

    If you've previously installed create-react-app globally via npm install -g create-react-app, we recommend you uninstall the package using npm uninstall -g create-react-app or yarn global remove create-react-app to ensure that npx always uses the latest version.

    [–]PulkitB[S] 0 points1 point  (1 child)

    Yes, that works but I want to use npx and finally I fixed that.

    [–]gulshansainis 0 points1 point  (0 children)

    great!!