skills/bun-guides-write-file-stdout/SKILL.md
Write to stdout
npx skillsauth add jarle/bun-skills Bun Write to stdoutInstall this skill globally with one command. Works with Claude Code, Cursor, and Windsurf.
3 of 9 scanners reported clean
Some scanners were skipped, did not run, or reported a non-clean status. Review each row below.
The console.log function writes to stdout. It will automatically append a line break at the end of the printed data.
console.log("Lorem ipsum");
For more advanced use cases, Bun exposes stdout as a BunFile via the Bun.stdout property. This can be used as a destination for Bun.write().
await Bun.write(Bun.stdout, "Lorem ipsum");
See Docs > API > File I/O for complete documentation of Bun.write().
development
Using TypeScript with Bun, including type definitions and compiler options
development
Learn how to write tests using Bun's Jest-compatible API with support for async tests, timeouts, and various test modifiers
testing
Learn how to use snapshot testing in Bun to save and compare output between test runs
testing
Learn about Bun test's runtime integration, environment variables, timeouts, and error handling