added regex to strip comments from js before parsing