Debugging Javascript in Safari
This is old hat, but I stay away from Javascript when I can, so it's new to me. Maybe it's new to you too.
Safari has apparently, for a while, allowed you to throw errors to its Javascript console for the purposes of debugging. This eliminates the bothersome alert() madness...
if (window.console) {
window.console.log("I think therefore I code!");
}
else {
alert("I think therefore I code!");
}
Nice...
Comments