Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

How can I change this behaviour to launch Chrome instead of IE with npm start? #1183

Open
sruthigit opened this issue Oct 27, 2017 · 5 comments

Comments

@sruthigit
Copy link

I am trying to build an Angular 2 application using VSCode editor. On my machine the default browser is IE. When I run npm start it launches the application in IE. But I want to launch my application in Chrome.How can I change this behaviour to launch Chrome instead of IE with npm start?

@AndresDevelop
Copy link

try this https://support.google.com/chrome/answer/95417?hl=en&co=GENIE.Platform%3DDesktop

It worked for me

@jasel-lewis
Copy link

I'm a little late to the party, but possibly this post post will help you. If the link ever breaks, it deals with injecting BROWSER='Chrome' into your start string (per the post, 'Google Chrome' did not work for me).

As an example, for my application I had the below which always opened in IE (work computer, can't change the default browser):
"scripts": { "start": "cross-env PORT=8080 react-scripts start" }

...and I changed to:
"scripts": { "start": "cross-env PORT=8080 BROWSER='Chrome' react-scripts start" }

@jasel-lewis
Copy link

...and here's why BROWSER='Google Chrome' did not work for me (I'm on a Windows system).

@SanDiegoCasey
Copy link

I found this thread, in my case I was trying to run npm Start from a CLI as administrator. When I went back to a regular CLI (not administrator) it launches from Chrome, which is good enough for what I needed.

@shubhammaheshan
Copy link

You See THis video solve your problem
https://www.youtube.com/watch?v=m-MzAA0TOvA&t=232s

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

5 participants