Home > Firebug, Javascript, Web Development > Javascript debug with Firebug (console.log)

Javascript debug with Firebug (console.log)

Do you waste countless hours debugging Javascript trying to figure out what it is happening? Alert much? Sometimes the simplest solutions are hidden in plain sight.

Look no more, just use this in your code…

console.log('so easy...:', yourVarObjectWhatever);

Then, just open up your Firebug console (you’re using it right?) and marvel at the wondreous info you were looking for all along. In a way it’s similar to a var_dump from PHP.

Yep, I didn’t know either. :(

Advertisement
  1. No comments yet.
  1. No trackbacks yet.

Leave a Reply

Fill in your details below or click an icon to log in:

WordPress.com Logo

You are commenting using your WordPress.com account. Log Out / Change )

Twitter picture

You are commenting using your Twitter account. Log Out / Change )

Facebook photo

You are commenting using your Facebook account. Log Out / Change )

Connecting to %s

Follow

Get every new post delivered to your Inbox.