Skip to main content

Dynamic API Endpoints in Astro

  • Can serve static data at any route in SSG mode without JS on the client (e.g. an rss feed)
  • Can serve dynamic data as well, but need an adapter that switches into SSR mode (nothing pre-rendered)

Original video by Coding in Public:

Join the early access for my course! https://learnastro.dev

πŸ”— Key Links πŸ”—
- Github: https://github.com/coding-in-public/astro-dynamic-endpoints

---------------------------------------

πŸ“Ή Related Videos πŸ“Ή
- Astro rendering options: https://youtu.be/aIHRjloFASU

---------------------------------------

⏲️ Timestamps ⏲️
0:00 Introduction
1:18 Dynamic static files
6:35 React w/ endpoint
11:15 SSR CRUD functionality
23:55 Dynamic routing with endpoints

---------------------------------------
🎨 VSCode Theming
- Font: Cascadia Code: https://github.com/microsoft/cascadia-code
- Theme: https://marketplace.visualstudio.com/items?itemName=Equinusocio.vsc-community-material-theme
- Icons: https://marketplace.visualstudio.com/items?itemName=BeardedBear.beardedicons

---------------------------------------

🌐 Connect With Me 🌐
- Website: https://codinginpublic.dev
- Blog: https://chrispennington.blog
- Twitter: https://twitter.com/cpenned
- Patreon: https://www.patreon.com/coding\_in\_public
- Buy Me a Coffee: https://www.buymeacoffee.com/chrispennington