import { showToast } from "vant";
import { i18n } from "@/i18n";
import { Toast } from '@capacitor/toast';

export function setup() {
  window["$msg"] = async (msg, position = "bottom", duration = 2000) => {

  await Toast.show({
    text: msg,
    position: position,
    duration: duration
  });

    // Toast({ position: position, message: msg });
  };

  window["$t"] = i18n.global.t;
  window["$web3"] = undefined;
}
