Update main.js

re-configured to set application extent if specified