When I run “npm start” to run a React app , it doesn't give any errors but hangs forever instead
I have already run "npm install
" before this and all the necessary dependencies have been installed.
I've also tried uninstalling the old version of NodeJS and installing the latest version but it's still not working.
A browser window with the React app should pop up.
My package.json file looks like this:
{
"name": "test",
"version": "0.1.0",
"private": true,
"dependencies": {
"add": "^2.0.6",
"bootstrap": "^4.1.3",
"react": "^16.6.3",
"react-bootstrap": "^0.32.4",
"react-dom": "^16.6.3",
"react-redux": "^5.1.1",
"react-router-dom": "^4.3.1",
"react-scripts": "2.1.1",
"react-select": "^2.1.1",
"redux": "^4.0.1",
"yarn": "^1.12.3"
},
"scripts": {
"start": "react-scripts start",
"build": "react-scripts build",
"test": "react-scripts test",
"eject": "react-scripts eject"
},
"eslintConfig": {
"extends": "react-app"
},
"browserslist": [
">0.2%",
"not dead",
"not ie <= 11",
"not op_mini all"
],
"proxy": "http://localhost:57111/"
}
reactjs npm npm-start
add a comment |
I have already run "npm install
" before this and all the necessary dependencies have been installed.
I've also tried uninstalling the old version of NodeJS and installing the latest version but it's still not working.
A browser window with the React app should pop up.
My package.json file looks like this:
{
"name": "test",
"version": "0.1.0",
"private": true,
"dependencies": {
"add": "^2.0.6",
"bootstrap": "^4.1.3",
"react": "^16.6.3",
"react-bootstrap": "^0.32.4",
"react-dom": "^16.6.3",
"react-redux": "^5.1.1",
"react-router-dom": "^4.3.1",
"react-scripts": "2.1.1",
"react-select": "^2.1.1",
"redux": "^4.0.1",
"yarn": "^1.12.3"
},
"scripts": {
"start": "react-scripts start",
"build": "react-scripts build",
"test": "react-scripts test",
"eject": "react-scripts eject"
},
"eslintConfig": {
"extends": "react-app"
},
"browserslist": [
">0.2%",
"not dead",
"not ie <= 11",
"not op_mini all"
],
"proxy": "http://localhost:57111/"
}
reactjs npm npm-start
Did you try to access the URL manually?
– Tico
Nov 24 '18 at 4:30
Can we see your package.json scripts?
– Shawn Andrews
Nov 24 '18 at 4:35
add a comment |
I have already run "npm install
" before this and all the necessary dependencies have been installed.
I've also tried uninstalling the old version of NodeJS and installing the latest version but it's still not working.
A browser window with the React app should pop up.
My package.json file looks like this:
{
"name": "test",
"version": "0.1.0",
"private": true,
"dependencies": {
"add": "^2.0.6",
"bootstrap": "^4.1.3",
"react": "^16.6.3",
"react-bootstrap": "^0.32.4",
"react-dom": "^16.6.3",
"react-redux": "^5.1.1",
"react-router-dom": "^4.3.1",
"react-scripts": "2.1.1",
"react-select": "^2.1.1",
"redux": "^4.0.1",
"yarn": "^1.12.3"
},
"scripts": {
"start": "react-scripts start",
"build": "react-scripts build",
"test": "react-scripts test",
"eject": "react-scripts eject"
},
"eslintConfig": {
"extends": "react-app"
},
"browserslist": [
">0.2%",
"not dead",
"not ie <= 11",
"not op_mini all"
],
"proxy": "http://localhost:57111/"
}
reactjs npm npm-start
I have already run "npm install
" before this and all the necessary dependencies have been installed.
I've also tried uninstalling the old version of NodeJS and installing the latest version but it's still not working.
A browser window with the React app should pop up.
My package.json file looks like this:
{
"name": "test",
"version": "0.1.0",
"private": true,
"dependencies": {
"add": "^2.0.6",
"bootstrap": "^4.1.3",
"react": "^16.6.3",
"react-bootstrap": "^0.32.4",
"react-dom": "^16.6.3",
"react-redux": "^5.1.1",
"react-router-dom": "^4.3.1",
"react-scripts": "2.1.1",
"react-select": "^2.1.1",
"redux": "^4.0.1",
"yarn": "^1.12.3"
},
"scripts": {
"start": "react-scripts start",
"build": "react-scripts build",
"test": "react-scripts test",
"eject": "react-scripts eject"
},
"eslintConfig": {
"extends": "react-app"
},
"browserslist": [
">0.2%",
"not dead",
"not ie <= 11",
"not op_mini all"
],
"proxy": "http://localhost:57111/"
}
reactjs npm npm-start
reactjs npm npm-start
edited Nov 25 '18 at 22:56
halfer
14.4k758109
14.4k758109
asked Nov 24 '18 at 4:27
Scarlett LouisScarlett Louis
34
34
Did you try to access the URL manually?
– Tico
Nov 24 '18 at 4:30
Can we see your package.json scripts?
– Shawn Andrews
Nov 24 '18 at 4:35
add a comment |
Did you try to access the URL manually?
– Tico
Nov 24 '18 at 4:30
Can we see your package.json scripts?
– Shawn Andrews
Nov 24 '18 at 4:35
Did you try to access the URL manually?
– Tico
Nov 24 '18 at 4:30
Did you try to access the URL manually?
– Tico
Nov 24 '18 at 4:30
Can we see your package.json scripts?
– Shawn Andrews
Nov 24 '18 at 4:35
Can we see your package.json scripts?
– Shawn Andrews
Nov 24 '18 at 4:35
add a comment |
1 Answer
1
active
oldest
votes
There may be various reasons for the url to not automatically open up in a browser but we will know whether the server started or not by manually opening the url in the browser.
Usually the server is started in port 3000
in localhost
. So the URL to access your site will be http://localhost:3000
by default when you use create-react-app.
Try opening the site manually at http://localhost:3000
Thank you so much. That link redirected to my site. But do you know why it doesn't open in a browser automatically?
– Scarlett Louis
Nov 24 '18 at 4:58
There can be various reasons. 1. Browser has issues with auto open, 2. terminal blocking opening up browser windows, 3. Some other security setting in the OS, etc. Can't say for sure without looking deep into everything.
– Dinesh Pandiyan
Nov 24 '18 at 5:02
add a comment |
Your Answer
StackExchange.ifUsing("editor", function () {
StackExchange.using("externalEditor", function () {
StackExchange.using("snippets", function () {
StackExchange.snippets.init();
});
});
}, "code-snippets");
StackExchange.ready(function() {
var channelOptions = {
tags: "".split(" "),
id: "1"
};
initTagRenderer("".split(" "), "".split(" "), channelOptions);
StackExchange.using("externalEditor", function() {
// Have to fire editor after snippets, if snippets enabled
if (StackExchange.settings.snippets.snippetsEnabled) {
StackExchange.using("snippets", function() {
createEditor();
});
}
else {
createEditor();
}
});
function createEditor() {
StackExchange.prepareEditor({
heartbeatType: 'answer',
autoActivateHeartbeat: false,
convertImagesToLinks: true,
noModals: true,
showLowRepImageUploadWarning: true,
reputationToPostImages: 10,
bindNavPrevention: true,
postfix: "",
imageUploader: {
brandingHtml: "Powered by u003ca class="icon-imgur-white" href="https://imgur.com/"u003eu003c/au003e",
contentPolicyHtml: "User contributions licensed under u003ca href="https://creativecommons.org/licenses/by-sa/3.0/"u003ecc by-sa 3.0 with attribution requiredu003c/au003e u003ca href="https://stackoverflow.com/legal/content-policy"u003e(content policy)u003c/au003e",
allowUrls: true
},
onDemand: true,
discardSelector: ".discard-answer"
,immediatelyShowMarkdownHelp:true
});
}
});
Sign up or log in
StackExchange.ready(function () {
StackExchange.helpers.onClickDraftSave('#login-link');
});
Sign up using Google
Sign up using Facebook
Sign up using Email and Password
Post as a guest
Required, but never shown
StackExchange.ready(
function () {
StackExchange.openid.initPostLogin('.new-post-login', 'https%3a%2f%2fstackoverflow.com%2fquestions%2f53455128%2fwhen-i-run-npm-start-to-run-a-react-app-it-doesnt-give-any-errors-but-hangs%23new-answer', 'question_page');
}
);
Post as a guest
Required, but never shown
1 Answer
1
active
oldest
votes
1 Answer
1
active
oldest
votes
active
oldest
votes
active
oldest
votes
There may be various reasons for the url to not automatically open up in a browser but we will know whether the server started or not by manually opening the url in the browser.
Usually the server is started in port 3000
in localhost
. So the URL to access your site will be http://localhost:3000
by default when you use create-react-app.
Try opening the site manually at http://localhost:3000
Thank you so much. That link redirected to my site. But do you know why it doesn't open in a browser automatically?
– Scarlett Louis
Nov 24 '18 at 4:58
There can be various reasons. 1. Browser has issues with auto open, 2. terminal blocking opening up browser windows, 3. Some other security setting in the OS, etc. Can't say for sure without looking deep into everything.
– Dinesh Pandiyan
Nov 24 '18 at 5:02
add a comment |
There may be various reasons for the url to not automatically open up in a browser but we will know whether the server started or not by manually opening the url in the browser.
Usually the server is started in port 3000
in localhost
. So the URL to access your site will be http://localhost:3000
by default when you use create-react-app.
Try opening the site manually at http://localhost:3000
Thank you so much. That link redirected to my site. But do you know why it doesn't open in a browser automatically?
– Scarlett Louis
Nov 24 '18 at 4:58
There can be various reasons. 1. Browser has issues with auto open, 2. terminal blocking opening up browser windows, 3. Some other security setting in the OS, etc. Can't say for sure without looking deep into everything.
– Dinesh Pandiyan
Nov 24 '18 at 5:02
add a comment |
There may be various reasons for the url to not automatically open up in a browser but we will know whether the server started or not by manually opening the url in the browser.
Usually the server is started in port 3000
in localhost
. So the URL to access your site will be http://localhost:3000
by default when you use create-react-app.
Try opening the site manually at http://localhost:3000
There may be various reasons for the url to not automatically open up in a browser but we will know whether the server started or not by manually opening the url in the browser.
Usually the server is started in port 3000
in localhost
. So the URL to access your site will be http://localhost:3000
by default when you use create-react-app.
Try opening the site manually at http://localhost:3000
answered Nov 24 '18 at 4:54
Dinesh PandiyanDinesh Pandiyan
2,475925
2,475925
Thank you so much. That link redirected to my site. But do you know why it doesn't open in a browser automatically?
– Scarlett Louis
Nov 24 '18 at 4:58
There can be various reasons. 1. Browser has issues with auto open, 2. terminal blocking opening up browser windows, 3. Some other security setting in the OS, etc. Can't say for sure without looking deep into everything.
– Dinesh Pandiyan
Nov 24 '18 at 5:02
add a comment |
Thank you so much. That link redirected to my site. But do you know why it doesn't open in a browser automatically?
– Scarlett Louis
Nov 24 '18 at 4:58
There can be various reasons. 1. Browser has issues with auto open, 2. terminal blocking opening up browser windows, 3. Some other security setting in the OS, etc. Can't say for sure without looking deep into everything.
– Dinesh Pandiyan
Nov 24 '18 at 5:02
Thank you so much. That link redirected to my site. But do you know why it doesn't open in a browser automatically?
– Scarlett Louis
Nov 24 '18 at 4:58
Thank you so much. That link redirected to my site. But do you know why it doesn't open in a browser automatically?
– Scarlett Louis
Nov 24 '18 at 4:58
There can be various reasons. 1. Browser has issues with auto open, 2. terminal blocking opening up browser windows, 3. Some other security setting in the OS, etc. Can't say for sure without looking deep into everything.
– Dinesh Pandiyan
Nov 24 '18 at 5:02
There can be various reasons. 1. Browser has issues with auto open, 2. terminal blocking opening up browser windows, 3. Some other security setting in the OS, etc. Can't say for sure without looking deep into everything.
– Dinesh Pandiyan
Nov 24 '18 at 5:02
add a comment |
Thanks for contributing an answer to Stack Overflow!
- Please be sure to answer the question. Provide details and share your research!
But avoid …
- Asking for help, clarification, or responding to other answers.
- Making statements based on opinion; back them up with references or personal experience.
To learn more, see our tips on writing great answers.
Sign up or log in
StackExchange.ready(function () {
StackExchange.helpers.onClickDraftSave('#login-link');
});
Sign up using Google
Sign up using Facebook
Sign up using Email and Password
Post as a guest
Required, but never shown
StackExchange.ready(
function () {
StackExchange.openid.initPostLogin('.new-post-login', 'https%3a%2f%2fstackoverflow.com%2fquestions%2f53455128%2fwhen-i-run-npm-start-to-run-a-react-app-it-doesnt-give-any-errors-but-hangs%23new-answer', 'question_page');
}
);
Post as a guest
Required, but never shown
Sign up or log in
StackExchange.ready(function () {
StackExchange.helpers.onClickDraftSave('#login-link');
});
Sign up using Google
Sign up using Facebook
Sign up using Email and Password
Post as a guest
Required, but never shown
Sign up or log in
StackExchange.ready(function () {
StackExchange.helpers.onClickDraftSave('#login-link');
});
Sign up using Google
Sign up using Facebook
Sign up using Email and Password
Post as a guest
Required, but never shown
Sign up or log in
StackExchange.ready(function () {
StackExchange.helpers.onClickDraftSave('#login-link');
});
Sign up using Google
Sign up using Facebook
Sign up using Email and Password
Sign up using Google
Sign up using Facebook
Sign up using Email and Password
Post as a guest
Required, but never shown
Required, but never shown
Required, but never shown
Required, but never shown
Required, but never shown
Required, but never shown
Required, but never shown
Required, but never shown
Required, but never shown
Did you try to access the URL manually?
– Tico
Nov 24 '18 at 4:30
Can we see your package.json scripts?
– Shawn Andrews
Nov 24 '18 at 4:35