JSFiddle - React, Tailwind, and code Playground
HTML
<input type="text" id="email">
<input type="text" id="login">
JavaScript
const emailEl = document.getElementById('email');
const loginEl = document.getElementById('login');
emailEl.addEventListener('input', function (evt) {
loginEl.value = emailEl.value.replace(/(@.*)/, '');
});