Uh oh!
There was an error while loading. Please reload this page.
GH-38936: [JS] initialize overrides for DOM and Node in IIFE - #39472
GH-38936: [JS] initialize overrides for DOM and Node in IIFE#39472domoritz wants to merge 1 commit into
Conversation
domoritz
commented
Jan 5, 2024
@nrabinowitz can you test this change? If we get it in my Monday, it will be in the next release. |
trxcllnt
commented
Jan 5, 2024
domoritz
commented
Jan 5, 2024
I see. The issue with my code is that the method might still be thrown away? |
trxcllnt
commented
Jan 5, 2024
@domoritz yes, I believe so. I'm not sure if there's a clean way to do this... |
trxcllnt
commented
Jan 5, 2024
What impact would setting |
domoritz
commented
Jan 6, 2024
My understanding is that it makes tree shaking much less effective but we should check to see the impact. Or is there some way to remove the side effect for example by extending the builder and batch reader base classes with the node and dom specific methods and then exporting an extended class? |
trxcllnt
commented
Jan 8, 2024
The internal factory functions that create builders will be creating instances of the non-extended class, but we could definitely use this strategy as a way to patch the prototypes w/ the static-property-initialized-by-an-IIFE style that defeats tree-shaking. |
nrabinowitz
commented
Jan 8, 2024
Sorry I missed this until now. Based on the discussion here, do you still want me to test this fix as it stands or should I wait for another approach? FWIW, my current workaround is to use a Webpack override to specify |
domoritz
commented
Jan 9, 2024
I'm curious whether it works or not.
How could that work? If someone imports only |
thisisnic
commented
Apr 21, 2026
Closing this PR as the Javascript codebase has now moved to https://github.com/apache/arrow-js |
Uh oh!
There was an error while loading. Please reload this page.