defining variables in Javascript -
i have many variables in javascript function , don't fit on 1 line declaration.
var query_string = $('list_form').serialize(), container = $('list_container'),position = container.cumulativeoffset(), layer = $('loaderlayer'), remote_url = "/web/view/list_offers.php?" + query_string;
is there way define these variables on multiple lines 1
var
keyword?
var query_string = $('list_form').serialize(), container = $('list_container'), position = container.cumulativeoffset(), layer = $('loaderlayer'), remote_url = "/web/view/list_offers.php?" + query_string;
if recall correctly, pattern advocated doughlas crackford declare multiple variables script needs.
quick tip: beawere of javascript hoisting :)
Comments
Post a Comment