-
Notifications
You must be signed in to change notification settings - Fork 75
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
Avoid instanceof
and remove the "node" export condition
#713
Comments
smaye81
added a commit
that referenced
this issue
Mar 11, 2024
This adds a type guard function for `PluginOptionError` so that `instanceof` is no longer used. For additional details, see #713
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
In connectrpc/connect-es#974, we override
ConnectError
's implementation ofinstanceof
to avoid the dual package hazard, which allows us to remove the "node" export condition, which causes problems with some bundlers.We need to take a similar approach here: Avoid the dual package hazard with
instanceof
, and remove the "node" export condition.There are many more uses of
instanceof
here that in Connect-ES, and we will need to take a more cautious approach, and also make sure that we do not regress on performance.The text was updated successfully, but these errors were encountered: