Update JS snippets (remove superfluous newlines)