createInstance static method

Future<ReownWalletKit> createInstance({
  1. required String projectId,
  2. String relayUrl = ReownConstants.DEFAULT_RELAY_URL,
  3. String pushUrl = ReownConstants.DEFAULT_PUSH_URL,
  4. required PairingMetadata metadata,
  5. bool memoryStore = false,
  6. LogLevel logLevel = LogLevel.nothing,
  7. IHttpClient httpClient = const HttpWrapper(),
})

Implementation

static Future<ReownWalletKit> createInstance({
  required String projectId,
  String relayUrl = ReownConstants.DEFAULT_RELAY_URL,
  String pushUrl = ReownConstants.DEFAULT_PUSH_URL,
  required PairingMetadata metadata,
  bool memoryStore = false,
  LogLevel logLevel = LogLevel.nothing,
  IHttpClient httpClient = const HttpWrapper(),
}) async {
  final walletKit = ReownWalletKit(
    core: ReownCore(
      projectId: projectId,
      relayUrl: relayUrl,
      pushUrl: pushUrl,
      memoryStore: memoryStore,
      logLevel: logLevel,
      httpClient: httpClient,
    ),
    metadata: metadata,
  );
  await walletKit.init();

  return walletKit;
}