Use angular js to check if the email exists in the data base
Check if username exists with AngularJS
It is always a better idea to check the entered username exists or not if you are allowing the users to choose username while registration. To do this in Angular need to create a method from where send $http request to check username. Call the method from the ng-keyup directive.
makitweb.com
https://www.codegrepper.com/code-examples/typescript/angular+email+pattern