How do i make a text show and after showing, wait some seconds and hide again?

i am trying to make a social network website in wix.com
and now i am doing the sign up page. i want to make like
if the username or email already exist, show a text
" This email or username already exist". and i dont want to this text
shows forever. i want to this text shows for some seconds and hide again!

how do i do it? can you help me please?:slightly_frowning_face::slightly_frowning_face:

$w("#text3").show()
//i want to put the seconds here to wait
$w("#text3").hide()

https://www.sitepoint.com/delay-sleep-pause-wait/

oh. then i can do like this?

$w("#text3").show();
setTimeout(() => {$w("#text3").hide(); }, 5000);

Yes. It should be possible.

thank you so much!