Copyright (c) 2011 Doron Katz. All rights reserved. DoronKatz registered under ABN 68 954 062 611. Apple, the Apple logo, iPod, iPod touch, and iTunes are trademarks of Apple Inc., registered in the U.S. and other countries. iPhone is a trademark of Apple Inc. App Store is a service mark of Apple Inc. Theme by Cory Watilo

FirebugTarget - A Flex Logging Tool I found

Hey folks, I came across this simple Flex logging when I was investigating the latest developments in the logging framework world, for my project at work. While I will do a good review of one of the best logging tools out there, Thunderbolt, for now I just wanted to bring up a simple blogging utility. It's called FireBugTarget and was made to be able to use Firefox's Firebug console, to log warnings, information, errors and so forth. I found it on Danny Patterson's blog, and he explained how he created a simple mx.logging framework implementation, and I have tested it on both Firefox and Internet Explorer (with Internet Development Tools). All you have to do to get this working is, put the .as file somewhere in amongst your packages and refer to it, as shown below:

import com.dannypatterson.logging.FirebugTarget;
import mx.logging.ILogger;
import mx.logging.Log;

var logger:ILogger = Log.getLogger("myLogger");
var logTarget:FirebugTarget = new FirebugTarget();
logTarget.addLogger(logger);
logger.info("info from flex");
logger.error("error from flex");
logger.warn("warn from flex");
logger.debug("debug from flex");