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

[configuration] Usage on browser's web worker #158

Closed
lenhan1000 opened this issue Jun 19, 2023 · 0 comments · Fixed by #159
Closed

[configuration] Usage on browser's web worker #158

lenhan1000 opened this issue Jun 19, 2023 · 0 comments · Fixed by #159

Comments

@lenhan1000
Copy link

image
The module is not useable in web worker without significant patching. Imo, this can be solved either:

  1. Let user dynamically insert the needed window.
  2. Fallback to jsdom if window is undefined.
  3. Make the Parser class more independent from HTML/DOM since i think the main functionality is still the "parse" function. I don't how feasible it is and can be wrong here.
@lenhan1000 lenhan1000 changed the title Usage on browser's web worker [configuration] Usage on browser's web worker Jun 19, 2023
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

Successfully merging a pull request may close this issue.

1 participant