1
0
Fork 0
mirror of https://github.com/denoland/deno.git synced 2024-11-29 16:30:56 -05:00
denoland-deno/cli/tests/testdata/stdout_write_all.ts

9 lines
227 B
TypeScript
Raw Normal View History

const encoder = new TextEncoder();
const pending = [
Deno.stdout.write(encoder.encode("Hello, ")),
Deno.stdout.write(encoder.encode("world!")),
];
await Promise.all(pending);
await Deno.stdout.write(encoder.encode("\n"));