Adds general javascript snippets