Hi Nice Tutorial, this is good but when we are re using the component that uses same store will be a problem. I am not sure how can we re use components that use same modules. even though I declared state as a function that returns state i cannot reuse them . Can you tell me how to achieve that?
@indranilbanerjee61423 жыл бұрын
Great tutorial ❤️! I have a quick question i.e I have a project with vuex store. Now in that parent project I am using another custom child project as dependency. So, will the vuex store of parent project be accessible in child project component also? Is there anyway? Thank you
@lansolo19915 жыл бұрын
I have a question concerning your 'initStore' action at 03:30 : you use async/await to fetch your jokes.json file. before comitting to the state. In my own project (the first one), in the vuex store, I use : import Myjson from ‘@/myjson.json’ then it directly feeds the state just with a ‘state: Myjson’. Actually, I don’t see the point using async await according to the fact it doesn’t seems to trigger something as soon as jokes.json is fetched.. Great tutorials by the way as always!
@ProgramWithErik5 жыл бұрын
lansolo1991 that’s a good one! Yes, you can directly import json that way, but I wanted to simulate the differences in using actions versus mutations. So just assume that the fetch was talking to a server instead
@wadday5 жыл бұрын
Your option is great for contents load locally like JSON file used. However like Eric said every data may not be hard coded, and majority we may fetch from some external or API source..
@murilolivorato14895 жыл бұрын
Hello my friend , wonderful tutorial . I have a question , I wold like to know if has any way to re use codes , or expand a class inside VUEX . I know that in VUE we have mixins , but I dont know if that it is possible to use in VUEX . I have many VUEX CRUD modules . for example POST_MODULE , POST_CATGEORY_MODULE , POST_USER_MODULE .... and All tff them has almost the same fuinctions , create() . delete() . update() , ..... How do you manage that to dont repeat the code ? Thanks
@bigonema95465 жыл бұрын
hello, i have seen your amazing videos. so, I'm trying to copy it, but there's an error. "[vuex] module namespace not found in mapGetters(): jokes/" Can i get a solution for this?
@Alex-Shohet5 жыл бұрын
please tell me which extension highlights the body function so beautiful
@ProgramWithErik5 жыл бұрын
I'm using Sarah Drasners Vuejs pack. marketplace.visualstudio.com/items?itemName=sdras.vue-vscode-extensionpack
@soklagenhet4 жыл бұрын
Great tutorial man, every other tutorial out there regarding namespaced modules overcomplicates it, but you really nailed it.
@asim-gandu-phenchod3 жыл бұрын
I have read your "Vuejs in Action" book. It was really a great book. Thanks for creating such a nice book
@ProgramWithErik3 жыл бұрын
Awesome thanks for checking it out!
@ProgramWithErik5 жыл бұрын
Vuex modules. Love it, hate it? Tell me all about it!
@wadday5 жыл бұрын
Loved it..
@chetankharel44355 жыл бұрын
i found easier to use vuex with vue than redux with react.
@newworld38445 жыл бұрын
Hey Erik, do you think there will eventually be more Vue jobs. I live in Los Angeles and there are hardly any. And most of those jobs are at design firms using laravel on the backend.
@ProgramWithErik5 жыл бұрын
Yes, I think it's slowly growing.
@jianjunxiao57795 жыл бұрын
great job, could i have your raw code at github, thanks in advanced !
@johnnydriesen75754 жыл бұрын
Watching this vid in June 2020, and it's still very accurate and helpful. Thanks for all your time and effort, Erik.
@ColinRichardson5 жыл бұрын
Strange way to find the latest id, seems a prime example of when to use array.reduce
@dvnarxx4 жыл бұрын
Thanks, Erik! I've been looking for a simple, lean video that explains exactly that!
@cheukkie5 жыл бұрын
For those who can't get the initStore part working. I had the same. I changed it to this to make it work: Object.keys(modules).forEach(moduleName => { if (modules[moduleName].actions && modules[moduleName].actions.initStore) { store.dispatch(`${moduleName}/initStore`); } });
@ProgramWithErik5 жыл бұрын
Thanks, weird you were having problems. I'll need to make an updated video
@netfan15874 жыл бұрын
Thanks! Wish you write this also in typescript!
@tubun095 жыл бұрын
Thank you so much. your github is not updated with this video tho
@fenkraken5 жыл бұрын
Fantastic video, thank you, Erik! Wanted to add future request, since you are probably more experienced with Vue than most people. In Vuex there is such thing as "watch" (it's in API reference at vuex official site). I wonder if it's better solution than to have a watchers for getters since it's baked directly into store (in my mind it can be used with some kind of cool vuex store notifications app-wide). Can you make a video about it? Maybe how it's different (if so) when used with Nuxt too. I think it would be great topic to have a video on. Thanks for you work!
@ProgramWithErik5 жыл бұрын
Good idea, I'll look into this!
@peoray5 жыл бұрын
Absolutely great tutorial. Learnt so much
@ProgramWithErik5 жыл бұрын
Thanks!
@jacquesduplessis61755 жыл бұрын
Great vid, thanks man! I was just playing around with modules last night and I ran into some thing you highlighted in this vid.
@ProgramWithErik5 жыл бұрын
Awesome!
@nitinuniyal83575 жыл бұрын
I have seen a lot of your videos. They have really helped me in picking the concept very easily. As you have a lot of experience in software developer. Can you make a video on improving coding skill, to help us become a good programmer.
@ProgramWithErik5 жыл бұрын
NITIN UNIYAL yes I will
@SebastianPerezG5 жыл бұрын
I'm just making something with vuex vue and Laravel and for me this is video was very usefull. Next time maybe you can make a video about vuetifyjs v-data-table and server side pagination / search with Laravel.
@ProgramWithErik5 жыл бұрын
My Laravel skills aren't so great, but this is a good idea :)
@SebastianPerezG5 жыл бұрын
@@ProgramWithErik No problem man, i asked that because there are very few tuts about vuetify with real examples.
@heyyy49875 жыл бұрын
Do it some with mongo express vue and node (MEVN). Tanks
@SebastianPerezG5 жыл бұрын
@@heyyy4987 That could work ...
@shuttereff3ct5933 жыл бұрын
Thanks, that's a great video!
@raccqa5 жыл бұрын
Great video, Thanks Eric!
@Rjktcj456rjktcj5 жыл бұрын
Amazing tutorial! Thank you very much for your work.
@hcivelek5 жыл бұрын
Thank you for the video. very clear.
@ProgramWithErik5 жыл бұрын
You are welcome
@mahmudulhasan13605 жыл бұрын
Best one i ever seen
@ProgramWithErik5 жыл бұрын
Awesome!
@mahmudulhasan13605 жыл бұрын
@@ProgramWithErik I've searched a lot but these videos make me complete.