You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
As discussed in Discord, this is being added to the esbuild in order to workaround modules that are expecting __dirname to be defined. It's my understanding that ion bundles code targeting ESNext and as such __dirname will not be set by nodejs. Any ES module that then tries to define __dirname will fail in ion.
I believe the approach should be that __dirname is never set by ion, unless opted-in, and even that feels out of scope for ion.
Another approach is that ion doesn't set __dirname with const. Still feels wrong to me but could be a good compromise.
The text was updated successfully, but these errors were encountered:
Possibly some wrong assumptions lie ahead..
As discussed in Discord, this is being added to the esbuild in order to workaround modules that are expecting
__dirname
to be defined. It's my understanding that ion bundles code targeting ESNext and as such__dirname
will not be set by nodejs. Any ES module that then tries to define__dirname
will fail in ion.I believe the approach should be that
__dirname
is never set by ion, unless opted-in, and even that feels out of scope for ion.Another approach is that ion doesn't set
__dirname
withconst
. Still feels wrong to me but could be a good compromise.The text was updated successfully, but these errors were encountered: