Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

add routeAfterAuthentication to the README #2285

Closed
wants to merge 1 commit into from
Closed
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
12 changes: 11 additions & 1 deletion README.md
Original file line number Diff line number Diff line change
Expand Up @@ -309,7 +309,7 @@ methods__ for handling authentication and invalidation of the session (which
not only happens when the user submits the login form or clicks the logout
button but also when the session is authenticated or invalidated in another tab
or window of the application). The `handleAuthentication` method will
transition to a configurable route while the `handleInvalidation` method will
transition to a [configurable route](http://ember-simple-auth.com/api/classes/Configuration.html) while the `handleInvalidation` method will
reload the page to clear all potentially sensitive data from memory. In order
to customize those behaviours, these methods can be overridden when the
application defines its own session service that extends the one provided by
Expand Down Expand Up @@ -341,6 +341,16 @@ export default class ApplicationAdapter extends JSONAPIAdapter {
}
```

### Redirecting to a route after authentication

Add the following to your app's config/envvironment.js file:

```js
ENV['ember-simple-auth'] = {
routeAfterAuthentication: 'dashboard',
};
```

## The Session Service

The session service is the main interface to the library. It defines the
Expand Down