© 2026 Hedgehog Software, LLC
console.log
import * as fs from "fs"; const filePath = `./logs/console/${new Date().toISOString().replace(/:/g, "_")}.txt`; const logStream = fs.createWriteStream(filePath, { flags: "a" }); // Append mode const originalLog = console.log; console.log = function(msg) { logStream.write(`${msg}\n`); originalLog.apply(console, msg); };
Join the Discord to ask follow-up questions and connect with the community
Sapphire is a next-gen object-oriented Discord.js bot framework.
2,286 Members