Create-react-app fails to create app structure - javascript

I am trying to use create-react-app to create a react app skeleton but this command miserably fails in between and ends up creating only half package.json and downloading not all node_modules
some such kind of half output
npm install --save-dev --save-exact react-scripts failedarPerm extractEntry _ba
It doesn't fail at the same point always, i am running this on a linux server with CentOS 7
Not getting whats wrong , any help is appreciated

Related

create-react-app not working ?? Any Help is Appreciated

just tried creating my first react app but surely react is not in a mood to welcome me.
Just after installing everything node and create-react-app even checking their versions to make sure they are installed.I moved on to creating the react app using npm create-react-app my-app command but it has given me this error and i am not able to resolve.
Any HELP will be appreciated.
I even tried updating the config file but Showed these errors as well.
As specified in the create-react-app github repository wiki. Please go through the detailed step by step instructions.
npx
npx create-react-app my-app
(npx is a package runner tool that comes with npm 5.2+ and higher)
npm
npm init react-app my-app
npm init is available in npm 6+
Yarn
yarn create react-app my-app
Reference Link: https://github.com/facebook/create-react-app#creating-an-app

Configuration instructions are not clear

Here is what they say about the configuration:
Make sure you have run npm install
Build the dist directory by running BUILD_MODE=dist npm run build
Establish a link to this repository by running npm link
No problem concerning nodejs installation or linking, but the line "running BUILD_MODE=dist npm run build", I don't know how to run that, it's not a valid command... Maybe I'm just dumb, but if you can explain to me how to do that, I'd appreciate it.
Oh and I'm on Windows 10
Thanks
For Windows, you will need to run below commands.
set BUILD_MODE=dist
npm run build
npm link

React + redux project not launching with instructions

This is my first React + Redux project, it works when I run it in my PC but when people follow my github instructions to run the project on their computers they get an error. "command not found: yarn"
Can anyone help me with this issue please? I wonder if my instructions are wrong in the first place
https://github.com/itsandromeda/Shoes-Store
If anyone gets to launch it succesfully without any errors please let me know.
Instructions:
Install dependencies
npm install
Install json server
npm install -g json-server
Run json server
json-server --watch db.json --port 3001
Launch project
yarn start
It all worked for me. I'm using node v8.9.4 and npm 5.6.0

How do I use two versions of Electron on the same machine

When I first started to learn Election the book I was using recommended that it be installed using npm install -g electron. Now I read on the npm website that npm install electron --save-dev is the preferred way to install it.
So I created a new project directory and ran npm init then ran
npm install electron --save-dev. According to package.json Electron 1.7.5 was installed, but when I type electron in the project directory it reports version 1.6.10 which is the version that was installed with the -g option.
Is there a way to get my new project to use 1.7.5? I have already completed a small project using version 1.6.10 and don't want to do anything that would keep it from running.
Thanks, Jim
You can run the local version of electron out of the node_modules/.bin directly -- most likely it will be called node_modules/.bin/electron.
You can use npm or gulp (or even a shellscript/batch file) to run the app for you.

Error when starting Node Application - MEAN Stack

I have started to create a Node js application using MEAN Stack so i have followed the steps in the following URL to intialize a node js Application using MEAN.
Link
When i provide GRUNT or Started the Node js Application in Terminal, I am getting the following error.
events.js:72
throw er; // Unhandled 'error' event
^
Error: ENOENT, open '/home/vigneshmoha/Documents/node/branding/public/system/lib/bootstrap/dist/css/bootstrap.css'
[nodemon] app crashed - waiting for file changes before starting...
npm version 1.4.15
Node js version v0.10.28
MongoDB version v2.6.1
I haven't changed anything else. Am i missing anything?
I am not sure about this but try installing bower with the command..
npm install -g bower
and then sudo bower install --allow -root
Now check if the files are created
try this
npm cache clean
npm install
I just had the exact same problem (on Mac OS X 10.9). Running npm install without sudo fixed it. Seems like bower is causing some troubles when used with sudo.
This error might be also due to errors in your Nodejs application. Fix the errors. You might also need to install bower:
npm install -g bower . tested on windows 10 and it worked.
Had the same issue., tried to delete node_modules, did npm install., but the scenario remained same.
On restarting the system, it seems to be back to normal.

Categories