Category "redux"

How to type properties in merging object for getInitialState of createEntityAdapter object?

I want to type status with FetchingStatus type. How to implement that? type FetchingStatus = 'idle' | 'loading' | 'succeeded' | 'failed'; const initialState =

React Redux state is not being updated when using useSelector inside useEffect

I'm new to react and when I'm updating my state in redux, I'm no able to see my state updated in my component inside a setInterval, despite the state in redux i

Multipart form parse error - Invalid boundary in multipart: None content-type issue?

I am working on simple CRUD with react and react-redux and having trouble with POST in client sideBoardList.js import React, { Component, Fragment } from 'reac

Redux Toolkit doesn't work well with WebStorm

I'm learning Redux and Redux Toolkit, but I don't understand why autocomplete doesn't work when I'm trying to dispatch an action (see the image below). I import

useSelector returns undefined - react-redux

I'm using react-redux. createSlice: import { createSlice } from "@reduxjs/toolkit"; const datatableSlice = createSlice({ name: "datatable", initialStat

How do I correctly implement Redux Saga action dispatches?

I'm currently playing around with redux saga and I'm having troubles implementing it correctly. Let's say I have a reducer which keeps track of how many times t

Exported variable 'store' has or is using name '$CombinedState' from external module error Redux toolkit and redux persist

Hi I'm trying to get redux persist working with redux toolkit (also in typescript) I'm getting the following error: Exported variable 'store' has or is using na

Reset state to initial with redux-toolkit

I need to reset current state to initial state. But all my attempts were unsuccessful. How can I do it using redux-toolkit? const showOnReviewSlice = createSlic

Why Context API is worse than Redux for high frequency updates?

I saw many articles that Redux is better than Context API in performance than high frequency updates, but nothing is specific and tell why. What makes people sa

how to know if i should use redux for my application or any other alternative?

I am new to react native and mobile development world. I am developing a mobile application with react native, it's basically an entreprise management app for H

Reat Native & RTK Query - Call an other endpoint when request is success

I am new in Redux & RTK Query and I do not understand how I can fetch data from another endpoint when response of another endpoint is succeed. I created an

How to reach the data from Redux devtool?

I want to reach the data of 'audience' under an endpoint where it shows in Redux dev tool of Google Chrome. Is it possible to reach it like we reach the localSt

How to update state ( initial State ) objects in reducer when using immer?

If have a state of objects payload: export const initialState = { payload: { firstName: 'Mick', lastName: 'Andri', phoneNumber: '

Async/Await not executing as expected

I have the below method where I am updating store and after store updating, I am performing certain activities based on store values - useEffect(()=>{ const

does redux change the reference of rootState object when a field's value in a sub state changes?

i have my redux states setup like this rootState subState1 field1 field2 subState2 field1 field2 multiple sub

disable other buttons using e.target.id

I have ten expansion panels. on click of one button in one expansion panel I need to disable other buttons in other expansion panel but the problem is when I tr

How to apply createEntityAdapter to createApi slice

I have implemented successfully a redux-toolkit api. Now Im trying to use createEntityAdapter to be able to use the pre-built selector methods. import { creat

How to cancel an entire redux saga chain from the leaf node

We have multiple sagas (ex: loadSampleData and loadCustomSampleData) that can be triggered by multiple different actions and can have multiple in-flight request

How to solve redux-persist failed to create sync storage. falling back to noop storage. in nextjs

Here is the version am using => "redux-persist": "^6.0.0", Error: => redux-persist failed to create sync storage. falling back to noop storage.

How can I merge multiple reducers?

I have a file structure like below store index.js reducers organize index.js user index.js index.js trying to combine organize and user reducers to reducers/