ruby on rails - Show users a message before they are logged out by timeout -
we have rails 4 app using devise authentication. want to:
- send user message 1 minute before his/her session automatically expires
- let user click button on message continue his/her session
- automatically send user login page , display message there if his/her session expire
are there devise extensions or build-in components this, or need roll our own solution? if start on our own, there tutorials accomplishing or documentation on devise hooks we'll interacting with?
it looks of when wrote answer, there weren't gems or devise hooks take care of me, had roll out own component.
one of difficult parts of writing component figuring out how send request server check how longer user had before being automatically logged out. didn't want sending request reset auto-log-out "timer." question explains how dealt task: devise - make request without resetting countdown until user logged out due inactivity
Comments
Post a Comment