Support providing Astro.locals through the adapter
Closed this issue · 1 comments
Csszabi98 commented
💻
- Would you like to work on this feature?
What problem are you trying to solve?
The first party astro node adapter supports providing Astro.locals when ran in middleware mode. It would be convinient to implement it for the aws adapter as well to enable easily passing data from the handler to Astro.
https://docs.astro.build/en/guides/middleware/
Describe the solution you'd like
Add a new optional parameter that enables supplying Astro.locals
Describe alternatives you've considered
As a workaround you can write Astro middlewares that can make request to s3 buckets for instance. (The problem is mixing responsibilities with this approach)
Documentation, Adoption, Migration Strategy
No response
lukeshay commented
This has been completed.