update: create a JavaScript file for init and get app's object