Seperated login page from rest of app. NodeJS server checks database for user account and sends back ok if use is found. Server then saves cookie on client for auth purposes