From 8bc158cf4a4bb0f062a12875b49bcba3a73a7181 Mon Sep 17 00:00:00 2001 From: Carmen Cabrera Date: Wed, 1 Nov 2023 09:48:25 -0400 Subject: [PATCH] add new example in Getting Started section --- README.md | 5 +---- examples/simpleInvoke/main.go | 4 ++-- 2 files changed, 3 insertions(+), 6 deletions(-) diff --git a/README.md b/README.md index 6022d73e..ac6935cc 100644 --- a/README.md +++ b/README.md @@ -57,10 +57,7 @@ operations on the wallets. The package has excellent documentation for a smooth - library documentation available at [pkg.go.dev](https://pkg.go.dev/github.com/NethermindEth/starknet.go). - [simple call example](./examples/simpleCall) to make a contract call to a mainnet contract - [deploy account example](./examples/deployAccount) to deploy a new account contract on testnet. - +- [invoke transaction example](./examples/simpleInvoke) to add a new invoke transaction on testnet. ### Run Examples diff --git a/examples/simpleInvoke/main.go b/examples/simpleInvoke/main.go index 4f6c483d..3e446e27 100644 --- a/examples/simpleInvoke/main.go +++ b/examples/simpleInvoke/main.go @@ -13,7 +13,7 @@ import ( "github.com/joho/godotenv" ) -// NOTE : Please add in your keys only for testing purposes, incase of a leak you would potentially lose your funds. +// NOTE : Please add in your keys only for testing purposes, in case of a leak you would potentially lose your funds. var ( name string = "testnet" //env."name" account_addr string = "0x06f36e8a0fc06518125bbb1c63553e8a7d8597d437f9d56d891b8c7d3c977716" //Replace it with your account address @@ -81,7 +81,7 @@ func main() { SenderAddress: accnt.AccountAddress, } - // Converting the contractaddress from hex to felt + // Converting the contractAddress from hex to felt contractAddress, err := utils.HexToFelt(someContract) if err != nil { panic(err.Error())