Javascript 3/5 - Uncaught syntax error


#1

Hi guys, I have spent quite a bit of time trying to figure this out for myself, but no joy. I seem to have been typing as per the hints but I get an error message "Uncaught syntax error: missing ) after argument list"

My code is as follows:

var main = function() {

$('.article').click(function() {

$('.article').removeClass('current');

$('.description').hide();



$(this).addClass('current');

$(this).children('.description').show();

}

}


$(document).ready(main);

#2

HELLO!!! @bertie78

There is a part in your code where you did not close the parentheses.
^^$('.article').click(function() { < this is where it's opened you need to replace the first } with }) and then it should work properly.