Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
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
Add Web Worker Offloading module #556
Add Web Worker Offloading module #556
Changes from all commits
93fdcc9
7780635
fdef498
3a51604
6c80047
2251f4a
8bbf34a
2a65e27
cbc172a
ead61f0
db90a04
28b5fab
9ea44b2
805b8bc
c96f06c
d299c3a
0de9671
aa5479a
a9bc409
134e092
b92d7a9
f6de312
96e3033
d18fc66
eb71def
bfeefb5
3ac9488
3a1bd8f
33774cd
a6c40b5
7f14576
a17ba9f
aad2200
846248f
38a5781
47ddefd
0ad4560
def2055
e0e8dd4
283f6f3
9c5feef
3804345
e899107
2c7a51f
6159750
15f5bf5
b2babb6
335daaa
d482043
f8bc701
0058897
073a813
21721c8
5a83f39
9ff7b82
5dfcfdf
d8c779c
7afe9e9
5bbcd2c
efd16cb
77f3907
6b0b88f
41f4c9a
1f46191
35412eb
0095e8f
195886b
f9f2a5e
File filter
Filter by extension
Conversations
Jump to
There are no files selected for viewing
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This will necessitate introducing a
.distignore
file to replace the.gitattributes
file as explained in #893 (comment).There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Do we really want to call the module Partytown?
IMHO usage of the Partytown library is just an implementation detail.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Agreed. A less-specific name would be "Web Worker Offloading". I asked Bard for some alternative names, and it suggested "Threadshift". I like that, but it is trademarked.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
That makes sense. If you have a certain name in mind, do let me know, and I will edit it.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
How about Web Worker Offloading for now?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
SGTM, some more names:
I will defer name selection to you.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Those are some good options but I like Web Worker Offloading.
The JS being offloaded may not be third-party. It may also be critical, but just offloaded so it can run in another thread.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Correct me if I'm wrong, but let's say you have an existing script in a theme like:
In order to opt-in this script to use Partytown, you'd have to do this if you wanted to opt-in from a separate plugin:
Is that right?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Yup, that should do the trick.