Nuxt Authentication with Laravel Sanctum

  Рет қаралды 32,887

Codecourse

Codecourse

Күн бұрын

Пікірлер: 55
@agun21st
@agun21st 3 жыл бұрын
best and easy tutorial for Laravel Sanctum with Nuxt Auth. Salute Sir. easiest explanation.
@SandmanGeek
@SandmanGeek 4 жыл бұрын
Nicely explained Alex. A video on Laravel Sanctum with GraphQL would be a great help as there are not many tutorials/guides, specifically with GraphQL.
@xLastxTemplarx
@xLastxTemplarx 3 жыл бұрын
Regarding what you said at 7:42 , you still need to add an index.js file inside the store folder, otherwise vuex will not work and you will need to refresh your page after logging in for example in order to see the changes.
@cla1814
@cla1814 3 жыл бұрын
Thank you missed this step. No wonder why login was not working.
@oussamavive1
@oussamavive1 3 жыл бұрын
thank you very much Alex! i finally got the 'stateful' meaning and get it working properly!!!
@ColorFR
@ColorFR 3 жыл бұрын
i have this issue: '...CSRF token mismatch..." any idea? i pasted 1 day on this problem
@MuhammadKhalilZarpio
@MuhammadKhalilZarpio 3 жыл бұрын
Please make a video on nuxt auth configuration with Laravel passport, reading everywhere since yesterday but not in luck. Thank you 💕
@muhammadfadzilah9394
@muhammadfadzilah9394 3 жыл бұрын
how to solve error with Session store not set on request. I using stateful sanctum
@jonice4229
@jonice4229 2 жыл бұрын
can you make a tutorial how to deploy this?
@АнтонРевякин
@АнтонРевякин 3 жыл бұрын
But how to register via auth-next???
@josuebarros-desenvolvedorw2490
@josuebarros-desenvolvedorw2490 3 жыл бұрын
how can I do a mult-auth??? different authentication for /admin and another for /user??? 2 separate dashboards, manipulating 2 separate user types (not role)
@rodrigoalejandrobravopina3624
@rodrigoalejandrobravopina3624 2 жыл бұрын
THX BRO STILL WORKING
@Mahmudulhasan-ts5hm
@Mahmudulhasan-ts5hm 4 жыл бұрын
how to use SPA auth and TOKEN auth both together ?
@RamuRamu-eu2sx
@RamuRamu-eu2sx 3 жыл бұрын
You did good tutorial on nuxt.js but registration and Login things makes us so difficult to understand can you add registration part on this
@ukandumichael7796
@ukandumichael7796 3 жыл бұрын
had no choice but to subscribe...great video..short and useful
@chineduchiaju2519
@chineduchiaju2519 2 жыл бұрын
Hey please on deployment, what would be the SESSION_DOMAIN
@Shatic
@Shatic 3 жыл бұрын
Thank you for this tutorial!
@OreefyOfficial
@OreefyOfficial 3 жыл бұрын
Is it possible? Laravel as backend and NuxtJs as a frontend to host into the same domain.
@r3n736
@r3n736 3 жыл бұрын
of course why not?
@Irsatechnologyco
@Irsatechnologyco 3 жыл бұрын
in LoginController Unhandled \Illuminate\Auth\AuthenticationException for throw new AuthorizationException
@JesusGil90
@JesusGil90 Жыл бұрын
It would be great if you can continue with Two Factor Authentication 😁
@iffar1830
@iffar1830 3 жыл бұрын
Why didn't you get the CORS issue when you requested /login endpoint even if you did not exclude that endpoint in config/cors.php ?
@AhmadZaki95
@AhmadZaki95 3 жыл бұрын
'/user' already return unauthentication !!!!
@КириллБелоусов-ы5е
@КириллБелоусов-ы5е 3 жыл бұрын
in which folder is the admin panel created? in client project or inside laravel project?
@gurmukhsingh-uh5qo
@gurmukhsingh-uh5qo 2 жыл бұрын
thank you for this video, was facing an issue with env var
@Insidious18
@Insidious18 3 жыл бұрын
Nice! Any idea how I can add Google signin to work with this setup?
@eslamabdallahabass5662
@eslamabdallahabass5662 2 жыл бұрын
This doesn't work with nuxt3
@pablodiazmateus2263
@pablodiazmateus2263 3 жыл бұрын
Hi Alex hope you are doing great. I'm having an issue deploying the Nuxt js + Laravel application. I have 2 index files ... of course I can't have them both ... The nuxtjs makes a index.html with all the app and the Laravel makes a index.php. So the issue is that if I left the nuxtjs one ... I can't access to Laravel Telescope/Horizon, and if I remove the index.html I can't access the Front-end I made with Nuxtjs. Any ideas - videos - recommendations about it ? Thanks in advance for your time !
@Mahmudulhasan-ts5hm
@Mahmudulhasan-ts5hm 3 жыл бұрын
show to add register in this process?
@ezekielwachira1691
@ezekielwachira1691 3 жыл бұрын
I was wondering on that but registering a user does not use nuxt auth with sactum, you have to manually do that, send an API request to a register route in your laravel project but you will encounter CORS issues when doing that, to remove the CORS issues, first you have to make a request to Sanctum CORS then make your register request to the server.
@jorgeluisborges8166
@jorgeluisborges8166 3 жыл бұрын
theme vscode?
@JenuelDevTutors
@JenuelDevTutors 3 жыл бұрын
is their a video about registering a new user?
@ezekielwachira1691
@ezekielwachira1691 3 жыл бұрын
I was wondering on that but registering a user does not use nuxt auth with sactum, you have to manually do that, send an API request to a register route in your laravel project but you will encounter CORS issues when doing that, to remove the CORS issues, first you have to make a request to Sanctum CORS then make your register request to the server.
@JenuelDevTutors
@JenuelDevTutors 3 жыл бұрын
@@ezekielwachira1691 oh yeah,, I actually figured it out, I create an API for my register function. Thanks :)
@ezekielwachira1691
@ezekielwachira1691 4 жыл бұрын
CORS issues happening
@chronyan
@chronyan 4 жыл бұрын
github.com/nuxt-community/proxy-module
@douglasokonu2653
@douglasokonu2653 3 жыл бұрын
I had the same problem and changed the paths on the config file: cors.php : 'paths' => ['api/*', '/sanctum/*'], then cleared cache with (important!): php artisan config:cache laravel doesn't load the cors.php config file edits until you clear the cache hence the cors error
@ezekielwachira1691
@ezekielwachira1691 3 жыл бұрын
@@douglasokonu2653 I solved it using proxy module 🤞
@alexnewman7853
@alexnewman7853 3 жыл бұрын
i have a problem with CORS on localhost. What to do?
@douglasokonu2653
@douglasokonu2653 3 жыл бұрын
I had the same problem and changed the paths on the config file: cors.php : 'paths' => ['api/*', '/sanctum/*'], then cleared cache with (important!): php artisan config:gache
@ivogacina4740
@ivogacina4740 3 жыл бұрын
you did not provide middleware:['auth'] in nuxt.config , means your routes are not procteded on client side , you can acess any route without being logged in.If you add that , like docs says , than refreshing the page always redirects you to login even if you are already logged in.This is broken lib completely, just look at git issues
@KAZUxVIEW
@KAZUxVIEW 3 жыл бұрын
Thanks a lot !
@siyabdev
@siyabdev 3 жыл бұрын
You're a GEM
@felipefl200
@felipefl200 4 жыл бұрын
Awesome and helpfull
@ViralTVAbyzer
@ViralTVAbyzer 4 жыл бұрын
great videos
@yonghunchoi8944
@yonghunchoi8944 3 жыл бұрын
great !!!
@benyaminrmb
@benyaminrmb 3 жыл бұрын
thanks . can u help me out when i get this error No 'Access-Control-Allow-Origin'
@douglasokonu2653
@douglasokonu2653 3 жыл бұрын
I had the same problem and changed the paths on the config file: cors.php : 'paths' => ['api/*', '/sanctum/*'], then cleared cache with (important!): php artisan config:gache then it worked
@omareliotorrescastillo4808
@omareliotorrescastillo4808 10 ай бұрын
@@douglasokonu2653 this solution does not work
@SohailKhan-9422
@SohailKhan-9422 4 жыл бұрын
Hi bro first comment
@jonahmarsden
@jonahmarsden 3 жыл бұрын
CORS errors everywhere. Tutorial is completely useless now, don't waste your time.
@jaspercaelan4998
@jaspercaelan4998 3 жыл бұрын
Same, doesn't work.
@JesusGil90
@JesusGil90 Жыл бұрын
@masaakiuechi6190
@masaakiuechi6190 Жыл бұрын
If you are having 401 unauthorized error after loggin, fix SANCTUM_STATEFUL_DOMAINS on .env file to " SANCTUM_STATEFUL_DOMAIN". It worked for me...
Laravel SPA Authentication - setup and common mistakes
16:55
You're Probably Using Nuxt Wrong
5:16
LearnVue
Рет қаралды 38 М.
Using a Laravel REST API with a NuxtJs App
15:43
Laravel
Рет қаралды 37 М.
Easily Add Authentication With Nuxt 3 + Supabase
14:23
John Komarnicki
Рет қаралды 17 М.
Nuxt Explained
8:33
Awesome
Рет қаралды 30 М.
Authentication in Vue using Laravel Sanctum
23:06
Andrew Schmelyun
Рет қаралды 72 М.
Laravel Websockets and Laravel Echo with Vue
12:45
Codecourse
Рет қаралды 51 М.
Authorization with HttpOnly Cookies in Nuxt3 - RealLifeApps
17:12
Laravel SPA Auth different domains
10:51
cdruc
Рет қаралды 9 М.
Mastering Advanced Nuxt.js with Daniel Roe
1:19:33
This Dot Media
Рет қаралды 13 М.