Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Support Astro.locals inside live editor #180

Open
oliverlynch opened this issue Dec 13, 2023 · 0 comments
Open

Support Astro.locals inside live editor #180

oliverlynch opened this issue Dec 13, 2023 · 0 comments

Comments

@oliverlynch
Copy link

I have setup my site navigation code using astro middleware to make it accessible sitewide via Astro.locals. Astro.locals is constant once the middleware is run - so I am wondering if it would be possible to define the Astro.locals constant inside the live editor.

This would also prove useful as a workaround for #154 - allowing collections information to be accessed within bookshop components in the live editor. I wouldn't expect the collections information to update live, only at build time.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant