We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
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
The library allow to execute a comparison between 2 Big values using the method of first one, and put the second as argument of method:
Big
var a = Big(100); var b = Big(5); var areEquals = a.eq(b);
There are circustances where a and/or b can be nothing. Then a static comparison method versions are very useful. Then instead of do this:
a
b
nothing
var areEquals = !a && !b ? true : !a || !b ? false : a.eq(b);
...it is possible to do this:
var areEquals = Big.eq(a, b);
The text was updated successfully, but these errors were encountered:
Yes, that could be useful.
I would probably go with
Big.eq = (a, b) => { try { return Big(a).eq(b) } catch { return false } };
But I don't want to add any further methods, thanks, static or otherwise.
Sorry, something went wrong.
Perfect, good!
Maybe, can a and b to be "equals" when they are "null" / "nothing" together?
No branches or pull requests
The library allow to execute a comparison between 2
Big
values using the method of first one, and put the second as argument of method:There are circustances where
a
and/orb
can benothing
. Then a static comparison method versions are very useful.Then instead of do this:
...it is possible to do this:
The text was updated successfully, but these errors were encountered: