javascript: adding examples