Files
xrpl-dev-portal/content/_code-samples/get-started/js/base.js
2021-10-12 19:16:20 -07:00

15 lines
332 B
JavaScript

// Wrap code in an async function so we can use await
async function main() {
// Define the network client
const client = new xrpl.Client("https://s.altnet.rippletest.net:51234/")
await client.connect()
// ... custom code goes here
// Disconnect when done so Node.js can end the process
client.disconnect()
}
main()