astro/examples/ssr/astro.config.mjs
Matthew Phillips 5e52814d97
Adapters v0 (#2855)
* Adapter v0

* Finalizing adapters

* Update the lockfile

* Add the default adapter after config setup is called

* Create the default adapter in config:done

* Fix lint error

* Remove unused callConfigSetup

* remove unused export

* Use a test adapter to test SSR

* Adds a changeset

* Updated based on feedback

* Updated the lockfile

* Only throw if set to a different adapter

* Clean up outdated comments

* Move the adapter to an  config option

* Make adapter optional

* Update the docs/changeset to reflect config API change

* Clarify regular Node usage
2022-03-24 07:26:25 -04:00

22 lines
403 B
JavaScript

import { defineConfig } from 'astro/config';
import svelte from '@astrojs/svelte';
import nodejs from '@astrojs/node';
// https://astro.build/config
export default defineConfig({
adapter: nodejs(),
integrations: [svelte()],
vite: {
server: {
cors: {
credentials: true,
},
proxy: {
'/api': {
target: 'http://127.0.0.1:8085',
changeOrigin: true,
},
},
},
},
});