worker: populate BroadcastChannel MessageEvent source#64334
worker: populate BroadcastChannel MessageEvent source#64334SudhansuBandha wants to merge 2 commits into
Conversation
8a9de03 to
98aaa6a
Compare
|
In the MDN documentation, https://developer.mozilla.org/en-US/docs/Web/API/MessageEvent/source
The threadId might be sufficient to work with the new API you folks were working on but I'm wondering if there's a technical limitation that makes diverging from the web api an absolute necessity? Ideally this would be the Worker Object, since one could immediately invoke |
jasnell
left a comment
There was a problem hiding this comment.
This is a breaking change making this a semver-major. It will need doc updates as well. I think we should instead try to find a way of doing this so that it's not a breaking change
|
Thanks for the review, @jasnell. I agree that changing |
|
@jasnell Source currently resolves to null. Why would this a breaking change when there is nobody in the forest to hear the tree fall? |
Populate the MessageEvent source property with the sender's worker thread ID for BroadcastChannel messages originating from worker threads. Fixes: nodejs#59053 Signed-off-by: Sudhansu Bandha <bandhasudhansu@gmail.com>
Codecov Report✅ All modified and coverable lines are covered by tests. Additional details and impacted files@@ Coverage Diff @@
## main #64334 +/- ##
========================================
Coverage 90.23% 90.23%
========================================
Files 741 741
Lines 241194 241355 +161
Branches 45432 45467 +35
========================================
+ Hits 217640 217798 +158
+ Misses 15129 15128 -1
- Partials 8425 8429 +4
🚀 New features to boost your workflow:
|
c3d7dcd to
e7d2e56
Compare
|
I have created an extension of the Undici based |
e7d2e56 to
e392e56
Compare
Populate the MessageEvent source property with the sender's worker thread ID for BroadcastChannel messages originating from worker threads.
Fixes: #59053