* update config schema
* adapt default route `prerender` value
* adapt error message for hybrid output
* core hybrid output support
* add JSDocs for hybrid output
* dev server hybrid output support
* defer hybrid output check
* update endpoint request warning
* support `output=hybrid` in integrations
* put constant variable out of for loop
* revert: reapply back ssr plugin in ssr mode
* change `prerender` option default
* apply `prerender` by default in hybrid mode
* simplfy conditional
* update config schema
* add `isHybridOutput` helper
* more readable prerender condition
* set default prerender value if no export is found
* only add `pagesVirtualModuleId` ro rollup input in `output=static`
* don't export vite plugin
* remove unneeded check
* don't prerender when it shouldn't
* extract fallback `prerender` meta
Extract the fallback `prerender` module meta out of the `scan` function.
It shouldn't be its responsibility to handle that
* pass missing argument to function
* test: update cloudflare integration tests
* test: update tests of vercel integration
* test: update tests of node integration
* test: update tests of netlify func integration
* test: update tests of netlify edge integration
* throw when `hybrid` mode is malconfigured
* update node integraiton `output` warning
* test(WIP): skip node prerendering tests for now
* remove non-existant import
* test: bring back prerendering tests
* remove outdated comments
* test: refactor test to support windows paths
* remove outdated comments
* apply sarah review
Co-authored-by: Sarah Rainsberger <sarah@rainsberger.ca>
* docs: `experiment.hybridOutput` jsodcs
* test: prevent import from being cached
* refactor: extract hybrid output check to function
* add `hybrid` to output warning in adapter hooks
* chore: changeset
* add `.js` extension to import
* chore: use spaces instead of tabs for gh formating
* resolve merge conflict
* chore: move test to another file for consitency
---------
Co-authored-by: Sarah Rainsberger <sarah@rainsberger.ca>
Co-authored-by: Matthew Phillips <matthew@skypack.dev>
* feat(vercel): Add support for image optimization API
* chore: changeset
* feat: implement image service
* feat: dev service
* feat: full local service
* fix: move assets check to astro:config:done
* feat: update with new settings
* fix: remove unused param
* test: add tsets
* fix: rename to imageService
* docs: add docs
* Apply suggestions from code review
Co-authored-by: Sarah Rainsberger <sarah@rainsberger.ca>
* docs(vercel): Add Added In mentions
---------
Co-authored-by: Sarah Rainsberger <sarah@rainsberger.ca>
Currently using rewrite with static files works but server rendered files with either edge or serverless function don't get rewritten.
See: https://github.com/withastro/astro/issues/6446
* fix(vercel): update getRequest to use undici
* Changeset
* haha ts-expect-error is a double-edged sword
---------
Co-authored-by: Nate Moore <natemoo-re@users.noreply.github.com>
* feat(intergration/vercel): add vercel analytics support
* docs(intergration/vercel): add vercel analytics prop
* docs(intergration/vercel): bump version to 3.1.0
* Update packages/integrations/vercel/README.md
Co-authored-by: Sarah Rainsberger <sarah@rainsberger.ca>
* docs(intergration/vercel): add file name for example
* feat(intergration/vercel): convert analytics to ts and support in edge
* docs(intergration/vercel): move file names to code blocks as comments
* fix(intergration/vercel): remove unused import
* feat(intergration/vercel): add analytics support to static mode
* chore(intergration/vercel): revert version change
* style(intergration/vercel): add a blank line after astro import
* chore(intergration/vercel): generate file by changeset
* Update .changeset/eighty-bobcats-deliver.md
Co-authored-by: Chris Swithinbank <swithinbank@gmail.com>
* Update packages/integrations/vercel/README.md
Co-authored-by: Chris Swithinbank <swithinbank@gmail.com>
* Update packages/integrations/vercel/src/analytics.ts
Co-authored-by: Chris Swithinbank <swithinbank@gmail.com>
* chore(intergration/vercel): simplify analytics script
---------
Co-authored-by: Sarah Rainsberger <sarah@rainsberger.ca>
Co-authored-by: Nate Moore <natemoo-re@users.noreply.github.com>
Co-authored-by: Chris Swithinbank <swithinbank@gmail.com>
* [ci] release
* Update changelogs (#5955)
* [ci] release
* Wrap astro 2.0 beta logs in `<details>`
* Add link to docs upgrade guide
* First pass cleaning up 2.0 release notes
* mdx changes from Sarah
* combine 5584 and 5842 in deno, image, netlify
* markdown/remark incl (5684 & 5769) to match mdx
* Tweak markdown/remark formatting
* Format astro-prism
* Format astro-rss
* Format create-astro
* Format cloudflare
* Format lit
* Format partytown
* Format node
* Format preact
* Format react
* Format solid
* Format svelte
* Format tailwind
* Format vercel
* Format vue
* Format telemetry
* Format webapi
* Format scripts
* Reinstate h3s for headings
Co-authored-by: Ben Holmes <hey@bholmes.dev>
* Reformat mdx
* astro & markdown/remark: Combine #5679 & #5684 changelogs
Co-authored-by: github-actions[bot] <github-actions[bot]@users.noreply.github.com>
Co-authored-by: Chris Swithinbank <swithinbank@gmail.com>
Co-authored-by: Sarah Rainsberger <sarah@rainsberger.ca>
Co-authored-by: Ben Holmes <hey@bholmes.dev>
Co-authored-by: github-actions[bot] <github-actions[bot]@users.noreply.github.com>
Co-authored-by: Matthew Phillips <matthew@skypack.dev>
Co-authored-by: Chris Swithinbank <swithinbank@gmail.com>
Co-authored-by: Sarah Rainsberger <sarah@rainsberger.ca>
Co-authored-by: Ben Holmes <hey@bholmes.dev>
* chore: Update engines field
* fix(deps): Remove node-fetch
* feat(polyfills): Remove node-fetch for undici
* feat(webapi): Remove node-fetch from the webapis polyfills for undici
* feat(core): Remove node-fetch for undici in Astro core
* feat(telemetry): Remove node-fetch for undici
* feat(node): Remove node-fetch for undici in node integration
* feat(vercel): Remove node-fetch for undici in Vercel integration
* chore: update lockfile
* chore: update lockfile
* chore: changeset
* fix(set): Fix set directives not streaming correctly on Node 16
* Try another approach
* Debugging
* Debug fetch
* Use global fetch if there is one
* changeset for lit
* Remove web-streams-polyfill
* Remove web-streams-polyfill license note
* Update .changeset/stupid-wolves-explain.md
Co-authored-by: Nate Moore <natemoo-re@users.noreply.github.com>
Co-authored-by: Matthew Phillips <matthew@skypack.dev>
Co-authored-by: Nate Moore <natemoo-re@users.noreply.github.com>
* Add Astro as a peerDependency
* Add changeset
* Update .changeset/thin-seahorses-worry.md
Co-authored-by: Bjorn Lu <bjornlu.dev@gmail.com>
Co-authored-by: Bjorn Lu <bjornlu.dev@gmail.com>
* Revert "Revert "Allow image-pool to be used as its own Worker (#5317)" (#5360)"
This reverts commit 20e60c6e08.
* Remove special image-pool.js moving around
* Merge in assetIncludes
* changeset
* Copy to chunk folder in SSR too
* Update tidy-shoes-yawn.md
* update adapter READMES to include astro add
* missing space
Co-authored-by: Yan Thomas <61414485+Yan-Thomas@users.noreply.github.com>
Co-authored-by: Yan Thomas <61414485+Yan-Thomas@users.noreply.github.com>
Co-authored-by: Matthew Phillips <matthew@skypack.dev>
* Start of work on astroConfig.mode === 'server'
* Add tests and more
* adapter -> deploy in some places
* Add fallback for `adapter` config
* Update more tests
* Update image tests
* Fix clientAddress test
* Updates based on PR review
* Add a changeset
* Update integrations tests + readme
* Oops
* Remove old option
* Rename `mode` to `output`
* Update Node adapter test
* Update test
* fred pass
* fred pass
* fred pass
* fix test
Co-authored-by: Fred K. Schott <fkschott@gmail.com>
* Adds support for Astro.clientAddress
* Pass through mode and adapterName in SSG
* Pass through the mode provided
* Provide an adapter specific error message when possible
* Integration README fixes
* More tweaks (mostly code backticks for filenames)
* Update changeset
* Few more tweaks
* Make sure code blocks all have a code language
* Use URLs of new docs pages for package homepage
* One more stray `<br>` 👢
* Standardise to `sh` instead of `shell`
* feat: support adapters and third part integrations by keywords
* refactor: add keywords to all official integrations
* docs: add adapter ex to astro add help
* nit: clarify astro add usage
* nit: highlight link
* fix: use process.exit(1) on error
* chore: changeset
* nit: bold integration name
* fix: log install instructions for adapters instead
* nit: change to logAdapterConfigInstructions
* Revert "fix: log install instructions for adapters instead"
This reverts commit 1a459f152b.
* feat: add hardcoded adapter export map
* refactor: inline adapter config log