• Parameters

    • wallet: BrowserWallet

      of the new Learner minting a Learner Token.

    • andamioConfig: AndamioConfig<CourseManagementConfig>
    • learnerAlias: string

      a string input in the app

    • nftArtURL: string

    Returns Promise<MintLearnerTokensTx>

    successful TxHash of a MinterLearnerTokenTx

    Example

    This is an experiment with including some extra helper functions in the documentation. It might make things overwhelming? Or it might be helpful!

    // Form Example
    const [formData, setFormData] = useState({
    tokenAlias: "",
    });

    // Handle user input
    const handleInputChange = (e: ChangeEvent<HTMLInputElement>) => {
    const { name, value } = e.target;
    setFormData({
    ...formData,
    [name]: value,
    });
    };

    ...

    // Build the transaction
    const MINT_LEARNER_TOKEN_TX = await prepareMintLearnerTokenTx(wallet, andamioConfig, formData.tokenAlias);
    const res = await MINT_LEARNER_TOKEN_TX.runTx();
    setTxHash(res);

Generated using TypeDoc