JSFiddle - React, Tailwind, and code Playground
HTML
<script src="https://code.jquery.com/jquery-1.12.2.min.js"></script>
<input type="text" id="email" value="blah@test.com" />
<button>
Get email!
</button>
JavaScript
var email = "blah@test.com";
alert(email.toLowerCase().substr(email.length - 3, 3));
$("button").click(function(){
alert($("#email").val().toLowerCase().substr($("#email").length - 3, 3));
});