user_signed_in?in apps, pages and components.
authenticate_user!in a before action.
togglecomponent which gets shown when the event
sign_in_failureis emitted. This event gets emitted in case our form submit was unsuccessful as we specified it in our
form_confighash. If the form is successful our app will make a transition to the page the server would redirect to.
newaction in order to render our sign in page and set the correct Matestack app in the controller.
method: :getin the configuration hash. We use a http GET request to sign out, because the browser will follow the redirect send from devise session controller and then Matestack tries to load the page where we have been redirected to. When we would use a DELETE request the action we would be redirected to from the browser will be also requested with a http DELETE request, which will result in a rails routing error. Therefore we use GET and need to configure devise accordingly by changing the