Skip to main content

Questions tagged [react-redux]

The react-redux package provides the official React bindings for Redux: the `useSelector` and `useDispatch` hooks and the `connect` higher-order component. Use this tag for questions about accessing and updating Redux state in React components.

-1 votes
0 answers
19 views

redux-toolkit No reducer provided for key "" [closed]

I'm getting the following error: No reducer provided for key "merchant" Store does not have a valid reducer. Make sure the argument passed to combineReducers is an object whose values are ...
TEJAS's user avatar
  • 1
0 votes
1 answer
26 views

Too many state variables in a reducer, but I want my component to render only when one of them changes

I created a reducer with many state variables, And I am using it in my component like- let gridData = useSelector((state: State) => state?.auditReducer).gridData; will my component only update when ...
Meg's user avatar
  • 39
1 vote
0 answers
29 views

React component re-rendering issue with redux-toolkit

I created a component const Audit = () => { let auditReducer = useSelector((state: State) => state?.auditReducer); let [isDataGridLoading, setIsDataGridLoading] = useState(true); ...
Meg's user avatar
  • 39
-1 votes
0 answers
14 views

Handling react auth with redux-persist

I am working on a React application that uses Redux for state management and Redux Persist for persisting the state. The authentication flow in my application involves receiving a token via a URL and ...
marlon's user avatar
  • 15
0 votes
0 answers
11 views

TypeError: Cannot destructure property 'currentUser' of 'useSelector(...)' as it is null

I am getting error Cannot destructure property 'currentUser' of 'useSelector(...)' as it is null. on this line const { currentUser } = useSelector((state) => state.user); in App.jsx Main.jsx ...
Hamza Azhar's user avatar
-1 votes
0 answers
15 views

Issue with Keycloak Redirect on App Refresh

i have two tabs open on the same browser, what i want to do is that if i login on one of the tab i dont want to be logged in on the second tab also. I am using redux toolkit redux persist and keycloak ...
Otonye Amietubodie's user avatar
0 votes
1 answer
16 views

Using Redux Persist [duplicate]

I was using Redux Toolkit and tried to use Redux Persist but on terminal it shows this. A non-serializable value was detected in an action, in the path: `register`. Value: [Function: register] Take a ...
kodeater's user avatar
-1 votes
0 answers
21 views

Redux State Does Not Change When Modified From useInterval

so im trying to load user data from localStorage and set it to the redux user state. heres what i have done: Where The User Is Being Used: import Fruit from "../components/Fruit" import { ...
AmirparsaDD's user avatar
-1 votes
0 answers
25 views

TypeError: Cannot read properties of undefined (reading 'numberOfCakes')

I am beginner to React and Redux I am trying to learn Redux with React. I have created a store in store.js as below - const redux = require("redux"); const createStore = redux.createStore; ...
codenostalgia's user avatar
-1 votes
0 answers
17 views

React RouterV6 Loaders

I try to use loader data from the router in my component, the routes where the loader function is in a separate file. The data is fetched via react-thunk and axios but I can't navigate exactly to this ...
VLP's user avatar
  • 1
-1 votes
1 answer
40 views

Redux Question: When <App/> Component re-renders, does it cause all selectors to run again

I have read in Redux docs: The selector will be run whenever the function component renders (unless its reference hasn't changed since a previous render of the component so that a cached result can ...
moath's user avatar
  • 9
-1 votes
0 answers
23 views

Accessing information from a redux store in the main app from a dynamically loaded React Module? [closed]

I am using React (18.2) built with Vite (5.0.0) using vite-plugin-federation (1.3.5) to split up my application into a main application and several modules which are dynamically loaded once a user ...
Christofer Dutz's user avatar
0 votes
1 answer
39 views

Redux 5 - Selectors that return a new reference (such as an object or an array) should be memoized warning occurs with filter array method

I am a beginner Redux learner. I have a React 18 app. I am using redux 5 and react-redux 9. When I run my application I get the below warning in my browser: AnecdoteList.jsx:14 Selector unknown ...
qqq's user avatar
  • 846
-1 votes
1 answer
35 views

How does useSelector hook impact performance when selecting individual properties vs. destructuring the state in Redux?

I am using Redux in my React application and I often need to extract values from the Redux store using useSelector. Here are the two approaches I have considered: Approach 1: Selecting individual ...
Ishu Modanwal's user avatar
-1 votes
0 answers
14 views

Error: could not find react-redux context value; please ensure the component is wrapped in a <Provider>: In my React Native, Django-restframework

I have setup my RTK Query in React Native (expo-router)/File based here files rtk/api.ts: import { createApi, fetchBaseQuery } from "@reduxjs/toolkit/query/react"; export const api = ...
Chatelo's user avatar

15 30 50 per page
1
2 3 4 5
1551