Limiting assets on the widget
By default, all assets are displayed when the widget is loaded. You can, however, limit the available cryptocurrencies to display only one or several in the 'You get' drop-down list.
- Default view with all assets:
- Displaying one asset can be useful for single-currency wallets:
Pass the following data to load the Widget with a single cryptocurrency:
const wertWidget = new WertWidget({
// ... other options ...
commodity: "XTZ",
network: "tezos",
commodities: JSON.stringify([
{
commodity: "XTZ",
network: "tezos",
},
]),
});
- You can show several commodities as well
In order to do so, pass the following data to Wert upon initialization:
const wertWidget = new WertWidget({
// ... other options ...
commodity: "BTC",
network: "bitcoin",
commodities: JSON.stringify([
{
commodity: "BTC",
network: "bitcoin",
},
{
commodity: "ETH",
network: "ethereum",
},
]),
});
Make sure to pass the correct commodity
and network
options for this feature to work. You can find them in the List of supported coins and blockchains
Updated 8 months ago