Skip to content

Instantly share code, notes, and snippets.

@orkunkl
Last active August 20, 2020 10:08
Show Gist options
  • Save orkunkl/f30ba2d3d34f47dbe3028ab5b3d75ff9 to your computer and use it in GitHub Desktop.
Save orkunkl/f30ba2d3d34f47dbe3028ab5b3d75ff9 to your computer and use it in GitHub Desktop.
const address = client.senderAddress;
const cw20 = CW20(client);
const initMsg: InitMsg = {
name: "DIZZ COIN",
symbol: "DIZZ",
decimals: 6,
initial_balances: [{ address, amount: "1000000" }],
mint: {
minter: address,
cap: "99900000000"
}
};
// CW20 smart contract code ID is 4
const codeId = 4;
const dizz = await cw20.instantiate(codeId, initMsg, "DIZZ");
console.log(`Contract: ${dizz.contractAddress}`);
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment