Skip to content

Commit

Permalink
docs(vite.config): add server proxy for future api requests
Browse files Browse the repository at this point in the history
  • Loading branch information
johnleider committed Jun 22, 2023
1 parent 40d22b7 commit c47e2b3
Showing 1 changed file with 3 additions and 0 deletions.
3 changes: 3 additions & 0 deletions packages/docs/vite.config.mts
Original file line number Diff line number Diff line change
Expand Up @@ -281,6 +281,9 @@ export default defineConfig(({ command, mode, ssrBuild }) => {

server: {
port: +(process.env.PORT ?? 8080),
proxy: {
'/api': process.env.PROXY ?? 'http://localhost:3005'
}
},

preview: {
Expand Down

0 comments on commit c47e2b3

Please sign in to comment.