Hide navbar when scrolling down

Lots of iOS apps hide the top bar when the user scroll down and brings it back when scrolling up. Is there a way to do this in ionic?