365体育足球滚球比分

All Questions

Tagged with
Filter by
Sorted by
Tagged with
0
votes
1answer
17 views

React functional component inside a loop calls api only returns the response for last element passed on api

Parent component data.map(eachData => ( <ChildComponent key={eachData.id} child={eachData} /> )) Child Component props.getChildData({id: id}); code calls Redux ...
0
votes
1answer
12 views

Testing reducer using Jest receiving state prefixed with “0”: {before the actual state}

So, I was working with Jest to test the reducer and I'm getting the following error Jest error: Expected: [{"assignedfrom": "", "isLoggedIn": false, "username": ""}, {"assignedfrom": "test"}] ...
-1
votes
0answers
12 views

In HTTP put requests, will they fail if the order of parameters in object we send differ from the order of parameters in the API?

The object I'm sending is saveObj (console.log) saveObj: code: "120" discountType: "absolute" discountValue: 100.56 id: "6" productId: "isurunuwanthilaka" purchaseCount: "...
-1
votes
1answer
20 views

How can i check if user input is empty (react)

so i have a basic todo react app and how can i check if the user enters an empty value How can i also make sure that the empty todo dosent get added to the todolist
0
votes
0answers
18 views

React Native listen position of element

I want to listen the position of a view I am moving with a pan responder. I am using the onLayout prop to get the width, height, x and y positions, but it only runs when the first render. Any ideas? ...
0
votes
1answer
23 views

How to Show Error Message Snackbar in ReactJS

I used redux and react-material in this code. I want to show the snackbar with the error message if there is an error. For now, let just use a static error message by this const errorMessage = "This ...
0
votes
0answers
29 views

what is the purpose of using 2 .then in http requests?

Please explain me the following code snippet.. I'm trying to send a PUT request to edit single region ... I want to get explained how the Success action is fired with 2 .then s.....and why to use 2 ....
0
votes
0answers
15 views

Next JS with react-redux HOC typescript error

I've been trying to get the types correct for a HOC that wraps most of the Next pages but I can't seem to get rid of all the type errors. With the current code, I am getting a type error on the ...
-1
votes
2answers
27 views

Can any one please tell me proper way to Develop Separate Undefined component in ReactJs

ReactJs I am trying to create separate reusable Undefined Component to handle undefined properties but initially its comes with undefined so passed children throwing "Cant read property error" here ...
0
votes
1answer
28 views

How to get data before the component mount?

I've a screen in my app that loads some data. But I think the component is mounting before the them load. Probably because the token was not generated yet. How can I do to this not happen without ...
0
votes
2answers
25 views

React when pass data to child throw props data duplicate

I'm create Activities function component and call child function component called Categories when i send categories list to Categories function component and log "props" data send twice first one ...
0
votes
2answers
27 views

AXIOS Post stay on PENDING in my REACT application

Below is the Redux Action code that will be dispatched whenever onSubmit of Create / Updating a profile: I am using AXIOS lib for making the below POST calls to the backend - MongoDB. const res = ...
0
votes
2answers
33 views

How do I trigger a call to dispatch using React Hooks?

I have a save function in a component that makes some calls to an API and changes my local state based on the response. I then want to dispatch an action once AND ONLY ONCE these calls to setState are ...
0
votes
1answer
13 views

Defining common methods for React functional component

I have created a 4 page application using typescript and hooks. There are few methods within each file which is common. Is there any way so that same methods can be extended in all file. Something ...
0
votes
1answer
19 views

React saving dynamic UI components

Is there any way in react to save UI and load it later ? I came across several solutions like saving the UI state into a database but this solution is not smart if you are building a dynamic ...

15 30 50 per page
1
2 3 4 5
799