Creating a LWC Bitcoin Currency Converter

We are going to add a Lightning Web Component that will be part of the Home page of our Salesforce environment. This LWC will make a callout to get currencies updates. Ideally you want to perhaps use a Quick Action or some other mechanism to stop making unnecessary callouts if you are not going to use the converter. For the sake of this tutorial we are just going to think that we have unlimited callouts and we don’t really care if we make a callout out every time we open our Home page… uh-huh!

We will be creating something like this: 

We are going to look to several things that will allow us to give a feel or style to this component using very simple LWC code. 

We are going to also use an HTTP call to get data so we can make sure our rates are up to date. We are going to add an error component, a spinner component, and a fireToast component to make this more interesting. 

Basically we are going to build this using the old Visualforce bitcoin converter on this Github:
Visualforce Bitcoin Currency Converter Repository

If you want to get all the LWC files first and do your thing, you can find them here on Github:
LWC Bitcoin Currency Converter Repository

Leave a Reply

Your email address will not be published.