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
Hey there! I'm trying to find a robust library to handle money in my applicaiton. dinero.js is by far the best one I've seen so far. I'm curious what the status is on V2? Are you looking for any additional help?
I'm more than happy to help. Writing another library to handle my specific use-case doesn't really make sense. I could fork dinero.js, but I don't like how JS community often ends up with multiple versions of the same library. I'd love for this to become the standard for Money.
Let me know!
Use case
I build Shopify Apps and I need a library to handle money. A few considerations for me:
I'm doing calculations on large sums and multiple by percentages, I want to make sure I was bigints.
I need a library where I can easily use strings for currency codes. Shopify's API returns an amount as a signed stringified decimal with arbitrary precision and a currency code as a string.
I need to easily convert the money back to a decimal format to make API calls.
Dinero.js works great for 1. Although, I find passing around the generic a bit combursome. I'm wondering if there's an easier way to abstract that.
Dinero.js doesn't work great for 2. I want to import from the currencies library but all those currencies are using the number generic. They're incompatible once I've set the calculator to use bigint. It's a ton of work to rewrite all those currencies with bigints. Also, looking up the currency from the string to the object is a bit annoying. Not too bad, as I can write a helper. I'm just thinking this could be something nice for the library to handle and maybe provide a simpler interface.
Dinero.js works great for 3. I used the toDecimal helper.
The text was updated successfully, but these errors were encountered:
Hey there! I'm trying to find a robust library to handle money in my applicaiton. dinero.js is by far the best one I've seen so far. I'm curious what the status is on V2? Are you looking for any additional help?
I'm more than happy to help. Writing another library to handle my specific use-case doesn't really make sense. I could fork dinero.js, but I don't like how JS community often ends up with multiple versions of the same library. I'd love for this to become the standard for Money.
Let me know!
Use case
I build Shopify Apps and I need a library to handle money. A few considerations for me:
Dinero.js works great for 1. Although, I find passing around the generic a bit combursome. I'm wondering if there's an easier way to abstract that.
Dinero.js doesn't work great for 2. I want to import from the currencies library but all those currencies are using the number generic. They're incompatible once I've set the calculator to use bigint. It's a ton of work to rewrite all those currencies with bigints. Also, looking up the currency from the string to the object is a bit annoying. Not too bad, as I can write a helper. I'm just thinking this could be something nice for the library to handle and maybe provide a simpler interface.
Dinero.js works great for 3. I used the
toDecimal
helper.The text was updated successfully, but these errors were encountered: