question-mark
Stuck on an issue?

Lightrun Answers was designed to reduce the constant googling that comes with debugging 3rd party libraries. It collects links to all the places you might be looking at while hunting down a tough bug.

And, if you’re still stuck at the end, we’re happy to hop on a call to see how we can help out.

`--open` flag not working in Parcel 2

See original GitHub issue

🐛 Bug Report

I tried passing --open to the parcel src/index.html command, but nothing happened. This feature works perfectly in the latest stable parcel-bundler package.

🎛 Configuration (package.json)

{
  "scripts": {
    "start": "parcel src/index.html --open"
  }
}

🤔 Expected Behavior

Parcel should open http://localhost:1234 in my default web browser.

😯 Current Behavior

Nothing happens.

🔦 Context

I tried to use the --open flag as I’m used to do in parcel-bundler.

💻 Code Sample

src/index.html:

hello world

package.json:

{
  "scripts": {
    "start": "parcel src/index.html --open"
  }
}
$ yarn start

🌍 Your Environment

Software Version(s)
Parcel 2.0.0-alpha.2.1
Node v13.0.1
Yarn 1.19.1
Operating System Windows 10 v1809 (x64)

Issue Analytics

  • State:closed
  • Created 4 years ago
  • Comments:5 (3 by maintainers)

github_iconTop GitHub Comments

2reactions
DeMoorJaspercommented, Jun 15, 2020

Ow yes it can, thanks for the heads up. For any future reference install parcel@nightly to have this fixed

1reaction
Taym95commented, Nov 20, 2019

I will take this issue!

Read more comments on GitHub >

github_iconTop Results From Across the Web

CLI - Parcel
The parcel CLI is the most common way to use Parcel. It supports three different commands: serve, watch, and build.
Read more >
parcel - npm
Start using parcel in your project by running `npm i parcel`. ... The actual (somewhat complete) documentation for Parcel 2 is available ...
Read more >
Parcel 2: The Best Frontend Bundler - YouTube
Today we're playing with Parcel 2 ! Parcel is an alternative to Webpack. It prides itself on being ready to use out of...
Read more >
Parcel does nothing and is not recognized as a command
It looks like you're having two problems - actually getting parcel installed correctly and getting unexpected output when you run it.
Read more >
How to Bundle a Web App with Parcel.js - DigitalOcean
Parcel.js is an open source bundler. ... If you're still having a problem, stop your server from running by pressing CTRL+C in your...
Read more >

github_iconTop Related Medium Post

No results found

github_iconTop Related StackOverflow Question

No results found

github_iconTroubleshoot Live Code

Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free

github_iconTop Related Reddit Thread

No results found

github_iconTop Related Hackernoon Post

No results found

github_iconTop Related Tweet

No results found

github_iconTop Related Dev.to Post

No results found

github_iconTop Related Hashnode Post

No results found