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
⚡️ perf: Bundle optimization! #71
Conversation
The latest updates on your projects. Learn more about Vercel for Git ↗︎
|
bfcfebe
to
47acd8b
Compare
@@ -744,13 +749,14 @@ const WalletProvider = function WalletProvider({ children }: { children: React.R | |||
// todo: sendTx reject => false | |||
console.log('[Wallet] sendTx', transaction) | |||
|
|||
const isSolanaTransaction = transaction instanceof Transaction | |||
const isSolanaTransaction = 'partialSign' in transaction |
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.
Why?
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.
Why?
instanceof
requires the import of a module, but my version checks for the presence of a property, but requires only the type to import
Check the diff on pictures
main
branchThis branch
Changelog:
sideEffects
, use pure functions everywhere, when it's possibleENUMS
toConstants
. Enum from Typescript does not support tree-shaking