@quirks/store
Version:
19 lines (18 loc) • 406 B
JavaScript
import { assertIsDefined as i } from "@quirks/core";
function o(t) {
return t.getState().wallet;
}
function d(t, n) {
const a = t.getState(), e = a.chains.find((c) => c.chain_name === n);
i(e);
const s = a.getAddress(e.chain_id);
return i(s), s;
}
function h(t, n) {
return t.getState().chains.find((e) => e.chain_name === n);
}
export {
d as getAddress,
h as getChain,
o as getWallet
};