wrapp app in proper javascript enclosure