openexchangerates / money.js

money.js is a tiny (1kb) javascript currency conversion library, for web & nodeJS
http://openexchangerates.github.io/money.js
MIT License
1.46k stars 127 forks source link

Get current exchange rate function #40

Open 6alaile opened 3 years ago

6alaile commented 3 years ago

Using this library to create a forex calculator. I would love if there was a way to combine two currencies into a single currency pair that can be used for calculations.

i.e. Currently to find an exchange rate, Base and Rate must be defined separately. Create a variable/method that can store both.