Structure javascript into modules.