I want to set a DOM objects css display property to 'block' for 2 seconds and then have it set back to 'none' after the 2 seconds. How can this be done in just javascript? I am really new to this so don't really get jquery just yet.
I tried
document.querySelector(".one-rolled-popup").style.display = "block";
and then set it to
document.querySelector(".one-rolled-popup").style.display = "none";
after some other operations but this just hides it completely