init static method

void init({
  1. required String projectId,
  2. required List<int> chains,
  3. CoreStorage storage = CoreStorage.localStorage,
  4. required bool enableAnalytics,
  5. required bool enableOnRamp,
  6. required Web3ModalMetadata metadata,
  7. required bool email,
  8. List<String>? socials,
  9. required bool showWallets,
  10. required bool walletFeatures,
  11. TransportBuilder? transportBuilder,
  12. List<String>? includeWalletIds,
  13. List<String>? featuredWalletIds,
  14. List<String>? excludeWalletIds,
})

Implementation

static void init({
  required String projectId,
  required List<int> chains,
  CoreStorage storage = CoreStorage.localStorage,
  required bool enableAnalytics,
  required bool enableOnRamp,
  required Web3ModalMetadata metadata,
  required bool email,
  List<String>? socials,
  required bool showWallets,
  required bool walletFeatures,
  TransportBuilder? transportBuilder,
  List<String>? includeWalletIds,
  List<String>? featuredWalletIds,
  List<String>? excludeWalletIds,
}) {
  window.web3modal.init(
    projectId.toJS,
    chains
        .map(
          (e) => e.toJS,
        )
        .toList()
        .toJS,
    storage.toJS,
    enableAnalytics.toJS,
    enableOnRamp.toJS,
    metadata._toJS(),
    email.toJS,
    socials.jsify() as JSArray<JSString>?,
    showWallets.toJS,
    walletFeatures.toJS,
    transportBuilder?.toJS,
    includeWalletIds?.jsify() as JSArray<JSString>?,
    featuredWalletIds?.jsify() as JSArray<JSString>?,
    excludeWalletIds?.jsify() as JSArray<JSString>?,
  );
}