Learn Vue JS course Learn Javascript and Vue JS Learn VueJS course Learn VueJS Tutorial

Laravel Backends for Vue.js 3

This lesson is free, but it requires you to Log in

Don't have an account? Enroll for free

Format the User Data Once

In this lesson, we create a getUser function within the useAuth composable to fetch the user data and format it with proper Date data types where applicable. This makes accessing our user data consistent and predictable.

You can think of what we’ve done here something like using casts or accessors in Laravel models.