@ledgerhq/coin-tron
Version:
Ledger Tron Coin integration
18 lines • 626 B
JavaScript
import { getTronSuperRepresentatives, hydrateSuperRepresentatives } from "../network";
export const preload = async () => {
const superRepresentatives = await getTronSuperRepresentatives();
return {
superRepresentatives,
};
};
export const hydrate = (data) => {
if (!data || !data.superRepresentatives)
return;
const { superRepresentatives } = data;
if (!superRepresentatives ||
typeof superRepresentatives !== "object" ||
!Array.isArray(superRepresentatives))
return;
hydrateSuperRepresentatives(superRepresentatives);
};
//# sourceMappingURL=preload.js.map