How can I access some variables inside
$(document).ready(function(){ var foo=0; var bar = 3; });
from Google chrome console? If I
You can't since the are in a closure space. Here it explains how closure works (How do JavaScript closures work? ). To access the varible just set a breakpoint inside the $(document).ready function
$(document).ready