My project was switch the webmap from public to private and it's pop up the box to ask for login. How can I bypass the dialog box and use the username, password to authenticate inside my app? I know in swift application or objective C, we can use the portal credential to login automatically. But inside javascript there is no such setting, any help?