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

Consider removing electron #99

Closed
giuseppeg opened this issue May 23, 2016 · 7 comments
Closed

Consider removing electron #99

giuseppeg opened this issue May 23, 2016 · 7 comments

Comments

@giuseppeg
Copy link

Hi, browser-run is awesome – thanks for building it!
I have a request, would it be possible to remove the default browser and make the package smaller? Electron alone is ~41MB and not everyone needs it.

@juliangruber
Copy link
Owner

can you describe the exact scenario in which electron being ~41mb is a problem?

@giuseppeg
Copy link
Author

problem is a bold word :)
The point is one (me?) might not use electron yet has to wait for those 41mb to download when Firefox for example is already installed on all Travis CI environments.
I am not trying to argue :) I just wanted to know your opinion on this idea.

@juliangruber
Copy link
Owner

oh, to me "problem" is not a bold word at all :) that's what programming is, problem solving.

so what really matters to you is travis build time, right? not the local install time

@giuseppeg
Copy link
Author

Both actually, but yeah obviously (Travis) CI build time is more important.

@juliangruber
Copy link
Owner

Locally the prebuilt binary will be cached so you don't have to download it again, just the regular npm install stuff.

We could remove electron and require users to install it themselves. Since electron is the most used option with this library though, it needs to work just right.

One problem you run into with a global electron installation is that versions might mismatch. Electron changes their api frequently, so it's important to have just the version of Electron you expect.

I value correctness over speed, so I'm closing this.

Of course you're always free to have your own fork of browser-run that comes without electron, and even publish it to npm.

@giuseppeg
Copy link
Author

fair enough

@fregante
Copy link
Contributor

fregante commented Apr 13, 2019

One problem you run into with a global electron installation is that versions might mismatch. Electron changes their api frequently, so it's important to have just the version of Electron you expect.

That applies to any other browser that’s not bundled, in fact Firefox seems to have stopped working in v66 (#145)

I think it makes sense to bundle Electron for ease of use. Probably most users just need to “test it in a browser”, even if Electron isn’t exactly a real browser… it’ll do.

However an alternative could be offered, or rather a browser-run-core version without Electron, and a browser-run version that wraps the core and adds Electron.

Kinda like babel-core doesn’t include anything, but lets you run modifiers on top of it, and babel-it that wraps all the tools to babelify your code in one package.

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

3 participants