better app initialization