create common javascript require main file for app

Share javascript files across app instead of loading different ones on
each page