Laravel Vue SPA Issue Tracker part 8: vuex application module

preview_player
Показать описание
Today on our laravel vue spa issue tracker part 8 we are going to implement a general vuex application model in order to have notifications(snackbars) on all pages where we have forms.

Рекомендации по теме
Комментарии
Автор

Nice Video Peter. Keep up the good work.

TheNerdyDev
Автор

Done watching! It was interesting to know how you handled notifications using Vuex store. As I'm using Quasar, I used the 'Notify' plugin which comes inbuilt and handles all its state management by itself.

Also I personally prefer to use the Laravel's error response as a notification in frontend, instead of our own custom message, because laravel responds with unique message for all sorts of validation errors too.

git commit -m "Implemented notifications for success and fail messages of Auth pages"

Thank you peter!

pratikrane
Автор

I finally got a green panel guys, I still have to play a bit with the settings, but I think it's better!

ProgrammingwithPeter
Автор

Hello first of all I want to congratulate you for this excellent tutorial. the problem that i have is when the snakbar closes by itself after a few seconds i have this problem "[viewx] do not mutate vuex store state outside mutation handlers."

karimamakrane
Автор

Hi, Peter
Can you tell me something
If you set timezone to config/app.php on Laravel
then the date is correctly recorded in the database, for example, 8:00.
Then we take this date together with the user from the database and pass it to vue.
Laravel pulls the date from the database as 8:00 (checked via dd), but the response comes to frontend-vue as 5:00

What is the reason?

NikolayKonshin
Автор

If enable strict mode (
const store = new Vuex.Store({
// ...
strict: process.env.NODE_ENV !== 'production'
})

Getting errors when snackbar disappears:
[vuex] do not mutate vuex store state outside mutation handlers

When you click the Close button, there is no error

NikolayKonshin
Автор

Did Peter commit today's work?



Yes.

kmata