2.0.1 • Published 8 years ago

apollo-auth v2.0.1

Weekly downloads
2
License
ISC
Repository
github
Last release
8 years ago

apollo-auth

Authentication module for Apollo

Public Methods

Actions

getUserData fetch the logged in user object from the server

import { getUserData } from 'apollo-auth/dist/client/actions';

Usage

Reducer

import user from 'apollo-auth/dist/client/reducer';

const rootReducer = combineReducers({
    user
});

Routes

import AuthRoutes from 'apollo-auth/dist/client/routes';

const routes = (
    <Route component={App}>
        {AuthRoutes}
    </Route>
);