Configurations

As seen before, to initialise Quirks it is necessary to pass an object with a valid configuration. Currently the library supports several configuration parameters to customise different layers (e.g. choose the storage type, the wallets to use, etc.).

Below is an in-depth look at all the elements that make up the Config type.

Usage

import { type Config,  } from "@quirks/store";
import {
  ,
  ,
  ,
  ,
  ,
} from "@quirks/wallets";
import {
   as ,
   as ,
} from 'chain-registry/mainnet/osmosis';
 
const : Config = {
  : [
    ,
    ,
    ,
    ,
    ,
  ],
  : [],
  : [],
  : ,
  : {
    : {
      : "info",
      : "<YOUR-PROJECT-ID>",
      : {
        : "React App",
        : "React App for WalletConnect",
        : "https://walletconnect.com/",
        : ["https://avatars.githubusercontent.com/u/37784886"],
      },
    },
  },
};

Types

PropTypeDefault
wallets
Wallet[]
[]
chains
Chain[]
[]
assetsLists
AssetLists[]
[]
autoConnect
boolean
true
autoSuggestions
boolean
true
signOptions
SignOptions
-
signerOptions
SignerOptions
-
persistOptions
PersistOptions<AppState>
defaultPersistOptions
walletConnectOptions
WalletConnectOptions
-

SignOptions

PropTypeDefault
preferNoSetFee
boolean
false
preferNoSetMemo
boolean
true
disableBalanceCheck
boolean
true

SignerOptions

PropTypeDefault
stargate
(chain: Chain) => Promise<StargateClientOptions | undefined>
-
signingStargate
(chain: Chain) => Promise<SigningStargateClientOptions | undefined>
-
signingCosmwasm
(chain: Chain) => Promise<SigningStargateClientOptions | undefined>
-

WalletConnectOptions

PropTypeDefault
providerOpts
UniversalProviderOpts
-
namespaces
{ cosmos: Omit<Namespace, 'chains'> }
{ cosmos: { methods: ['cosmos_getAccounts', 'cosmos_signDirect', 'cosmos_signAmino'], chains: [], events: ['chainChanged', 'accountsChanged'], }, }

On this page