fix: Fix promise examples minor typos in comments and variable name. Capitalise comments (#276)
This commit is contained in:
@@ -1,15 +1,15 @@
|
||||
// required imports
|
||||
// Required imports
|
||||
const { ApiPromise } = require('@polkadot/api');
|
||||
const { WsProvider } = require('@polkadot/rpc-provider');
|
||||
|
||||
async function main () {
|
||||
// initialise the provider to connect to the local node
|
||||
// Initialise the provider to connect to the local node
|
||||
const provider = new WsProvider('ws://127.0.0.1:9944');
|
||||
|
||||
// create the API and wait until ready
|
||||
// Create the API and wait until ready
|
||||
const api = await ApiPromise.create(provider);
|
||||
|
||||
// retrieve the chain & node information information via rpc calls
|
||||
// Retrieve the chain & node information information via rpc calls
|
||||
const [chain, nodeName, nodeVersion] = await Promise.all([
|
||||
api.rpc.system.chain(),
|
||||
api.rpc.system.name(),
|
||||
|
||||
Reference in New Issue
Block a user