Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Change in account file #4

Open
wants to merge 8 commits into
base: main
Choose a base branch
from
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
4 changes: 2 additions & 2 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -69,7 +69,7 @@ const tokenOutAddress = tokens["usdc"].address;
const tokenInDecimals = tokens["eth"].decimals;
const inputAmount = BigNumber.from(parseUnits("1", tokenInDecimals));

// Usege on your website
// Usage on your website

const starknet = await connect({ showList: false })

Expand Down Expand Up @@ -128,7 +128,7 @@ const approveCall:Call = await fibrous.buildApprove(
tokenInAddress,
);

await account.execute([approveToken, swapCall])
await account.execute([approveCall, swapCall])

```

Expand Down
2 changes: 1 addition & 1 deletion docs/CONTRIBUTING.md
Original file line number Diff line number Diff line change
Expand Up @@ -47,7 +47,7 @@ Please adhere to the following guidelines when submitting code:

## License

By contributing to this project, you agree that your contributions will be licensed under the [project's license](../LICENCE).
By contributing to this project, you agree that your contributions will be licensed under the [project's license](../LICENSE).

## Conclusion

Expand Down
2 changes: 1 addition & 1 deletion examples/package.json
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
{
"name": "fibrous-sdk-examples",
"version": "0.2.0",
"version": "0.3.4",
"description": "Examples for using Fibrous SDK",
"main": "index.js",
"author": "kermo & zetsuboii",
Expand Down
9 changes: 3 additions & 6 deletions examples/src/account.ts
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
import { Account, CairoVersion, Provider } from "starknet";
import { Account, CairoVersion, RpcProvider, constants } from "starknet";

export function account(
privateKey: string,
Expand All @@ -8,12 +8,9 @@ export function account(
enum NetworkName {
SN_MAIN = "SN_MAIN",
SN_GOERLI = "SN_GOERLI",
SN_GOERLI2 = "SN_GOERLI2",
}
const provider = new Provider({
sequencer: {
network: NetworkName.SN_MAIN,
},
const provider = new RpcProvider({
nodeUrl: constants.NetworkName.SN_MAIN
});
const account0 = new Account(
provider,
Expand Down