Guy Aloni
@guy-aloni
Zaragoza, Spain
- Member Since
- Jun 4, 2024
- Lessons Completed
- 8
- Comments Contributed
- 8
- Hours Watched
- 1.7
Recent Activity
Here's what @guy-aloni has been up to this past year
-
Completed lesson How To Create Your Own Global Helpers in AdonisJS
-
Replied to Thanks for watching, Guy! For that, I'd recommend using Drive...
Thanks. I tried it but got problems with relative and absolute path, and could not manage to have the same code working with both
fs
ands3
depending on the environment argumentDRIVE_DISK
. I understand that basically the same code should work for both, I will give it another try :-) -
Commented on post Uploading and Displaying User Avatars
Thanks Tom for the tutorial!
I am trying to implement upload action that will work in localhost with file-system, and in production with s3. Can you please tell how to do it with minimum code? I guess that usingDRIVE_DISK
in.env
file should be enough, but I do not manage to have the same code working for both s3 and local file system. -
Upvoted comment Can you please tell me how to upload image in s3 in adonis js...
-
Upvoted comment Anytime!! Happy to hear you got it all working!
-
Replied to Hi Guy! Yeah, the VineJS date validation will return back a ...
Thanks Tom!
In my case, just if someone has the same problem, I had to add also an ISO format:startDate: vine.date({ formats: { utc: true } }).transform((date) => DateTime.fromJSDate(date)),
-
Upvoted comment Hi Guy! Yeah, the VineJS date validation will return back a ...
-
Commented on post Validating Form Data with VineJS
Great tutorial, thanks!
How can I validate dates? I get an errorUncaught Exception: Invalid value for "Chapter.startDate". It must be an instance of "luxon.DateTime"
, looks like date should be cast inside the validator? -
Completed lesson Validating Form Data with VineJS
-
Completed lesson Defining Our Models
-
Completed lesson The Basics of CRUD
-
Upvoted comment The expiry time should be included with the initial token, so...
-
Commented on post AdonisJS 6 Access Token Authentication in 20 Minutes
Another question - how do you combine an access-token authentication with social authentication?
https://docs.adonisjs.com/guides/authentication/social-authentication -
Commented on post AdonisJS 6 Access Token Authentication in 20 Minutes
Thank you very much for the clear and detailed explanation!
I wonder whether should be a good idea to add token expiration protection in front-end level, or rely on 409 server response in order to delete the token. -
Completed lesson AdonisJS 6 Access Token Authentication in 20 Minutes
-
Upvoted comment Hi Guy! The auth process shown in this series is for session...
-
Commented on post Logging Out An Authenticated User
I use access tokens, and when I do either
await auth.use('api').logout()
I get an errorauth.use(...).logout is not a function
.
I can neither get the token explicitly usingauth.use('api').token
(I get undefined).
The only way I can get it is from the request header, but I find it hard to believe that there is no way to extract it from the auth. Anyway, since the hashed token is stored, I don't even know whether the approach of searching for it in the DB will work. -
Completed lesson Logging Out An Authenticated User
-
Completed lesson Authenticating A Newly Registered User
-
Completed lesson Protecting Routes with Auth, Guest, and Admin Middleware
-
Commented on post The Flow of Middleware
Why do you apply the guest middleware for each route instead of applying it to the entire group?
-
Account created Welcome to Adocasts, @guy-aloni!