-
Notifications
You must be signed in to change notification settings - Fork 20
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
SDK v1 Example #322
base: master
Are you sure you want to change the base?
SDK v1 Example #322
Conversation
This pull request is automatically being deployed by Amplify Hosting (learn more). |
|
||
// Create a connection to a KILT blockchain. | ||
// let api = await Kilt.connect('wss://peregrine.kilt.io/') | ||
let api = await Kilt.connect('ws://localhost:9944/') |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
maybe just use a descriptive const?
let api = await Kilt.connect('ws://localhost:9944/') | |
let api = await Kilt.connect(FULL_NODE_WEB_SOCKET_URL) |
// The submitter account must have enough funds to cover the deposit costs. | ||
const submitterMnemonic = | ||
'build hill second flame trigger simple rigid cabbage phrase evolve final eight' | ||
const submitter = Crypto.makeKeypairFromUri(submitterMnemonic, 'sr25519') |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
this will change in the next prerelease, so when you port this over to bundle tests, use generateKeypair
instead.
// - `getSubmittable`: Produces transaction that can be submitted to a blockchain node for inclusion, or signed and submitted by an external service. | ||
|
||
// Submit transaction. | ||
// Note: `submit()` by default, waits for the block to be finalized. This behaviour can be overwritten |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I think the default currently is inBlock
- that's something we should discuss again
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
but the awaitFinalized
is true by default, no?
No description provided.