Skip to content

Console

Output functions for debugging. These compile directly to their JavaScript console equivalents.

FunctionSignatureDescription
Console.logT -> ()Log a value
Console.warnT -> ()Log a warning
Console.errorT -> ()Log an error
Console.infoT -> ()Log info
Console.debugT -> ()Log debug info
Console.timestring -> ()Start a named timer
Console.timeEndstring -> ()End a named timer and print duration
Console.log("hello")
Console.warn("careful")
// Timing
Console.time("fetch")
const data = try fetchData()?
Console.timeEnd("fetch")