---
title: "Discussion on \"React Auth Reducer\" | Hashnode"
description: "Discussion on \"React Auth Reducer\". import * as actionType from '../actions/AuthAction'\n\nexport const initialState = {\n    token: null,\n    userId:null,\n    error:null,\n    isLoading:false\n}\n\n\nconst AuthReducer = (state=initialState, action)=>{\n    switch(action.type){\n        case act..."
url: "https://hashnode.com/posts/react-auth-reducer/60178b84a4a28d1fcefce19d"
---

[Feed](https://hashnode.com/feed) /

Discussion

# [React Auth Reducer](https://thilina.hashnode.dev/react-auth-reducer?utm_source=hashnode&utm_medium=feed)

import \* as actionType from '../actions/AuthAction' export const initialState = { token: null, userId:null, error:null, isLoading:false } const AuthReducer = (state=initialState, action)=>{ switch(action.type){ case act...

Feb 1, 2021 · 1 min read · thilina.hashnode.dev  
Read the article

-   [#reactjs](https://hashnode.com/tag/reactjs)

## Written by

[thilina dilshan](https://hashnode.com/@Thilina)

@Thilina

  
[View profile](https://hashnode.com/@Thilina)

Software developer

## Responses

Markdown supported · ⌘↵ to post

No responses yet.
