valid braces in js