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
Having an object as input considerably improves the code robustness and scalability as devs won't ever need to worry about in which order they are adding the input parameters.
E.g. on the swap function the first 2 and the last 2 parameters have the same type, so they could be easily swapped without resulting in obvious errors. Which means subtle changes in code could be missed. Whereas if we had an object as input this would most likely never happen without being noticed.
This task is about moving all functions to the single-object-input pattern and follow this code convention moving forwards.
Since this refactor would result in lots of BREAKING CHANGES it seems to merit a 2.0 release.
The text was updated successfully, but these errors were encountered:
CassioMG
changed the title
[TS Wallet SDK] Release 2.0 to consolidate object as function input
[TS Wallet SDK] Consolidate object as function input
Oct 28, 2024
*This task depends on this other spike task
Discussion: #166 (comment)
The TS Wallet SDK currently has a mix of functions taking several parameters as input and functions taking a single object as input.
E.g.:
Having an object as input considerably improves the code robustness and scalability as devs won't ever need to worry about in which order they are adding the input parameters.
E.g. on the
swap
function the first 2 and the last 2 parameters have the sametype
, so they could be easily swapped without resulting in obvious errors. Which means subtle changes in code could be missed. Whereas if we had an object as input this would most likely never happen without being noticed.This task is about moving
all functions
to thesingle-object-input pattern
and follow this code convention moving forwards.Since this refactor would result in lots of
BREAKING CHANGES
it seems to merit a2.0
release.The text was updated successfully, but these errors were encountered: