I learnt redux from this series an year earlier, now I was stuck and was trying to deal with redux ascynchronously, I watched this again and I realized how much this series taught me, the video is still the same but I am with much more knowledge and skill, thanks to this video series and thank you TechSith !
You really made the complex subject seem so simple. I am learning to use redux and thunk and have had my nerves stretched by unclear tutorials, but this one was an exception. Liked and subscribed. Keep going :)
i really learn a lot from your tutorials. These are the easiest tutorial available. I have completed one of the top udemy course on react/redux. But this is way better than that. Thanks for all the effort.
Man there are always haters out there, I started looking at redux from code, and most of it made no sense to me till I found his explanations, couldn't be clearer, followed the entire redux series. I think he is quite concise and explains so well, he even explained the word thunk hahaha.. With short and concise videos.
Thank you man for your great effort to give the quality content. I Have question, "Reducers must not do any asynchronous logic, calculate random values, or cause other "side effects" but how these middleware achieve the asynchronous logic integration.
Can we dispatch from a setTimeout in mapDispatchToProps() without thunk middleware ? will it have dispatch as closure property even if we don't use thunk? I just want to understand if we can make async call then dispatch without thunk or not. and if so then what is the purpose of thunk
Actions must be plain objects. Use custom middleware for async actions. This is the error you get if you try to use setTimeout or any async action. Hope it helps.
Hello, While going through this tutorial, I had a doubt. That is... we are doing all of this just to make things async., we captured the action, now we said that (it's from your example) if we will first save the value to the server and then will update the state, but in this case: suppose the current state's value is 5 (which is showing on UI) and user clicks the ageUP button, then user would like to send the updated value to the server (which will be '6' in this example), but the updation will only take place when the action would reach reducer. Before updating the state, we have called the server via middleware...to save the value (which will be 5 not 6) How will I be able to send the updated value to server ?
You should probably switch around the names of ageUp and ageUpAsync. Its a little confusing as in the video the asynchronous function is called ageUp, and the synchronous function is called ageUpAsync xD
how does 'dispatch' parameter come in on ageUp function? export const ageUp = val => { return dispatch => { setTimeout( () => dispatch(ageUpAsync(val)), 2000 ); } };
@@sivanesh-s Exactly, for example the video named it 'dispach' which I believe is a typo. But that well (accidentally) illustrates the idea that it is just a parameter name XD
you told in this vedio that u are going to make another one in which u would show the get and post on server with redux implemented .. where is it sith?? can't find it ? by the way u are running an awsome tutorial series on ur own
In setTimeout why we need to add dispach, can we just call ageUpAsnc, dispatch is already there in mapDispachToProps. Tried to figure it out but still not getting it.
basically for async actions, we need to dispatch an event from mapDispachToProps then catch it with the redux thunk, and finish the async evert ( which is just settimeout in this case) and then dispatch it again to it with reach the reducer.
why state. loading is not mapped with reducer state{}. Please confirm, without mapping in reducer we are changing the state true. Is this the correct way?
Hey I'm struggling with redux my question is if i say switch(action.type) { case goap: return newstate default: return state } my question is when i dispatch the action goUp(1) i got count: undefined why this happen to me
tutorial is good but honestly, redux is outdated like a dinosaur. there are better options now like reactquery and whoever is learning redux now must have been living under a rock
Unfortunately, I can't fix it after the release of the video. But, I can be careful next time. I am not a great speller but I make up the short comings with my coding skill. :)
Great... This helped it to FINALLY begin to make sense!
I learnt redux from this series an year earlier, now I was stuck and was trying to deal with redux ascynchronously, I watched this again and I realized how much this series taught me, the video is still the same but I am with much more knowledge and skill, thanks to this video series and thank you TechSith !
I am glad that you keep coming back to watch these videos, I feel great as a teacher.
You really made the complex subject seem so simple. I am learning to use redux and thunk and have had my nerves stretched by unclear tutorials, but this one was an exception. Liked and subscribed. Keep going :)
THanks for watching Klaus.
Nothing is confusing, Its plain simple and amazing !
i really learn a lot from your tutorials. These are the easiest tutorial available. I have completed one of the top udemy course on react/redux. But this is way better than that. Thanks for all the effort.
Love this and the earlier custom middleWare which you created. Thanks
I’m guessing the 2 people who hit dislike don’t know what React or redux is. That’s about as good of an explanation as it gets
Man there are always haters out there, I started looking at redux from code, and most of it made no sense to me till I found his explanations, couldn't be clearer, followed the entire redux series. I think he is quite concise and explains so well, he even explained the word thunk hahaha.. With short and concise videos.
You are a real guru of technology sir god bless you for providing such videos sir live long🙏
Thanks Kranthi!
you are my favorite teacher that i never had. Thx for those cool videos
Thanks David, Its good know that I am able to channel the knowledge. :)
clean and clear explanation i have ever seen 👌
Glad it helped
Awesome tutorial, now i got basic redux , THAX lots sir
Awesome tutorial, I'm following the series and learning so quick!
Thanks a lot!
Awesome tutorial..! Good explanation
Glad it helped! Thanks for watching!
Thanks for the video! Easy to understand, follow, and fully demonstrates how/why to use thunk. Thanks so much!
In love with your react series.Amazing explanation :)
I love your tutorials
Thanks for watching!
I love this explanation
Exceptionally well explained ! Cheers Man
Awesome. Very clear
Awesome series, very helpful. Thank you, jedi
Brilliant and beautifully explained.
Thanks for watching!
. *You're Great!*
indians are...
Really helping me man, struggling to get a job so I'm making a whatsapp project
Awesome Tutorial! Thank you!
Thank you man for your great effort to give the quality content. I Have question, "Reducers must not do any asynchronous logic, calculate random values, or cause other "side effects" but how these middleware achieve the asynchronous logic integration.
Can we dispatch from a setTimeout in mapDispatchToProps() without thunk middleware ? will it have dispatch as closure property even if we don't use thunk? I just want to understand if we can make async call then dispatch without thunk or not. and if so then what is the purpose of thunk
Thank you.
Actions must be plain objects. Use custom middleware for async actions.
This is the error you get if you try to use setTimeout or any async action.
Hope it helps.
Thats really impressive.
You are the GREAT teacher. Thank you very much :))))
Thanks for you good video. It helped.
Hello,
While going through this tutorial,
I had a doubt. That is...
we are doing all of this just to make things async., we captured the action,
now we said that (it's from your example) if we will first save the value to the server and then will update the state, but
in this case: suppose the current state's value is 5 (which is showing on UI) and user clicks the ageUP button, then user would like to send the updated value to the server (which will be '6' in this example), but the updation will only take place when the action would reach reducer. Before updating the state, we have called the server via middleware...to save the value (which will be 5 not 6)
How will I be able to send the updated value to server ?
in that case you dont update value in the reducer. you simply set the new value in the reducer. this way the backend and frontend is sync.
Awesome :)
Grate job! Awesome tutorial!
It's funny how we have to create all this extra boilerplate just to bury the asynchronous functions more and more without any actual gain.
You are the best! If you have made some udemy class I would buy it!
You should probably switch around the names of ageUp and ageUpAsync. Its a little confusing as in the video the asynchronous function is called ageUp, and the synchronous function is called ageUpAsync xD
how does 'dispatch' parameter come in on ageUp function?
export const ageUp = val => {
return dispatch => {
setTimeout( () => dispatch(ageUpAsync(val)), 2000 );
}
};
That will be Provided by the redux-thunk middleware. Which gets this function returned in ageUp() and calls it with dispatcher argument
@@sivanesh-s Is it necessary
to call it dispatch?
@@djslimcodes2337 Not really it is just the argument. You can name it anything
@@sivanesh-s Exactly, for example the video named it 'dispach' which I believe is a typo. But that well (accidentally) illustrates the idea that it is just a parameter name XD
Good explanation
You are the best, thank you
when you imported actionCreator from actions... i am getting error on this.. apparently there is no actionCreator in actions.js
getting the same. will let you know if I figure it out.
change the import statement to:
import { ageUp, ageDown } from './store/actions/actions';
Also just noticed that he adds:
import * as actionCreator from "./store/actions/actions';
which solves the problem.
at 14:46 can we place dispatch(loading()) above return? i guess we cant but why?
As you could see, dispatch is a parameter which is a function, so if you place dispatch(loading()) above the return statement, dispatch is undifined.
Can you point me to that "Server interaction video" please? thank you
you told in this vedio that u are going to make another one in which u would show the get and post on server with redux implemented .. where is it sith?? can't find it ? by the way u are running an awsome tutorial series on ur own
Hi at 5.18 Ur import action creater from store/action/action Wer is this action creation declared in that file?
If its a default export you can name it whatever when you import it. Basically actionCreater becomes action
Got it. Thanks buddy :-)
In setTimeout why we need to add dispach, can we just call ageUpAsnc, dispatch is already there in mapDispachToProps. Tried to figure it out but still not getting it.
basically for async actions, we need to dispatch an event from mapDispachToProps then catch it with the redux thunk, and finish the async evert ( which is just settimeout in this case) and then dispatch it again to it with reach the reducer.
why state. loading is not mapped with reducer state{}. Please confirm, without mapping in reducer we are changing the state true. Is this the correct way?
What extension do you use to highlight a code block? :)
manual :)
that was awesome
NICE TUTORIAL!
Great!
Any plans of you doing videos on Epics redux observable
Not at the moment but I will put it in the queue of videos to make :)
Kem cho sir ?
tame react easy kari di du :)
Thank You.
Sir tame tips and tricks regarding video banao ne on react. please
muze south ind laga
you are awesome
got a subscriber
Thanks Dav for subscribing. :)
Please help me..While refreshing page my redux state is clearing why....
Hey I'm struggling with redux my question is if i say switch(action.type) { case goap: return newstate default: return state } my question is when i dispatch the action goUp(1) i got count: undefined why this happen to me
Where is the next video?
Awesome
Isn't a thunk just a promise then?
Hurts my ears when I hear him say basically ^^
Beisicaliii, I'm fkn dieing right here
Again :)))
@techsith lmgtfy.com/?q=basically+pronunciation Other than this, thank you! Lovely content ^^
Yeah but you're not actually awaiting it in the calling code... so you don't know if / when if finishes / succeeds or fails...
can i translate your video in albanian language?
*dispatch
i hate small screen :(
Sorry, its very hard to display this in a zoom . Were you watching on mobile device?
tutorial is good but honestly, redux is outdated like a dinosaur. there are better options now like reactquery and whoever is learning redux now must have been living under a rock
Please fix your spelling sir
Unfortunately, I can't fix it after the release of the video. But, I can be careful next time. I am not a great speller but I make up the short comings with my coding skill. :)
What mistake is it about, can you indicate the minute, Please?
volume is too LOW
seen
Thanks for a comment felix. :)
@@Techsithtube youtube is really bad at tracking which videos I have seen, so I put a "seen" in all the videos comments i see, so i know i've seen it
:) its a good idea. You can also create a playlist of seen videos .
Brilliant and beautifully explained.