Working in a Windows Mobile Project a realized that it was so hard to debug, because of the lack of a decent debugger. So I wrote MIEL a 7.3k script that let you insert logging in your code. You have 5 levels of logging log, debug, info, warn and error and you can view the source code of the page.
Here the example code:
<html>
<head>
<title>Miel Test</title>
</head>
<body>
</body>
<script type="text/javascript" src="miel.js">
</script>
<script type="text/javascript">
// Init Logger
miel.logger();
// Test logging
miel.log("log");
miel.debug("debug");
miel.info("info");
miel.warn("warn");
miel.error("error");
// View Source Code of the actual page
miel.viewSourceCode();
</script>
</html>
You can find it in the svn here http://code.google.com/p/yvmobile/source/browse/#svn/trunk/miel