Skip to content

Separate Browser.mainLoop from the browser API functions #5355

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

Closed
curiousdannii opened this issue Jul 2, 2017 · 9 comments
Closed

Separate Browser.mainLoop from the browser API functions #5355

curiousdannii opened this issue Jul 2, 2017 · 9 comments

Comments

@curiousdannii
Copy link
Contributor

curiousdannii commented Jul 2, 2017

If you use EmterpreterAsync it pulls in the whole Browser object, which is about 30KB of code. The majority of this is not required by EmterpreterAsync. It would be possible to separate out Browser.mainLoop and the handful of other functions which are needed (resumeAsyncCallbacks, pauseAsyncCallbacks, etc.)

While it may be possible, I'm not sure how much work it would be or whether it would be worth it... but it doesn't hurt to post an issue suggesting it.

@curiousdannii
Copy link
Contributor Author

curiousdannii commented Aug 18, 2017

@stale
Copy link

stale bot commented Aug 30, 2019

This issue has been automatically marked as stale because there has been no activity in the past 2 years. It will be closed automatically if no further activity occurs in the next 7 days. Feel free to re-open at any time if this issue is still relevant.

@stale stale bot added the wontfix label Aug 30, 2019
@curiousdannii
Copy link
Contributor Author

I haven't looked at this for a while. Is Browser still included with the new ASYNCIFY mode?

@stale stale bot removed the wontfix label Aug 30, 2019
@kripken
Copy link
Member

kripken commented Aug 30, 2019

@curiousdannii looks like it is. For similar reasons, it needs to check the main loop, uses asyncLoad, etc.

I agree it would be nice to refactor those out. However, I hope this already would be pretty well minified when closure is enabled, as it can remove unneeded properties of things?

@curiousdannii
Copy link
Contributor Author

Ah, I haven't used Closure. Guess I'll give it a try.

@stale
Copy link

stale bot commented Aug 29, 2020

This issue has been automatically marked as stale because there has been no activity in the past year. It will be closed automatically if no further activity occurs in the next 30 days. Feel free to re-open at any time if this issue is still relevant.

@kripken
Copy link
Member

kripken commented Aug 31, 2020

I think this would still be nice to do. Could be a useful refactoring!

@curiousdannii
Copy link
Contributor Author

I no longer need this, #12181 removed mainLoop itself from my output. But I'll still keep working on it as it will probably be helpful for others.

@stale
Copy link

stale bot commented Sep 21, 2021

This issue has been automatically marked as stale because there has been no activity in the past year. It will be closed automatically if no further activity occurs in the next 30 days. Feel free to re-open at any time if this issue is still relevant.

@stale stale bot added the wontfix label Sep 21, 2021
@stale stale bot closed this as completed Apr 17, 2022
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging a pull request may close this issue.

2 participants