Add proxy for easy external api access (DOCKER BROKEN!!)
This commit is contained in:
parent
5c099f5b49
commit
f51b811b55
@ -14,6 +14,15 @@ export default defineConfig({
|
||||
}),
|
||||
|
||||
vite: {
|
||||
plugins: [tailwindcss()]
|
||||
plugins: [tailwindcss()],
|
||||
server: {
|
||||
proxy: {
|
||||
'/api': {
|
||||
target: 'http://localhost:8080',
|
||||
changeOrigin: true,
|
||||
rewrite: (path) => path.replace(/^\/api/, '/api'),
|
||||
},
|
||||
}
|
||||
}
|
||||
}
|
||||
});
|
@ -1,4 +1,5 @@
|
||||
import Pocketbase from "pocketbase"
|
||||
|
||||
export const client = new Pocketbase(import.meta.env.PUBLIC_PB_URL)
|
||||
const client = new Pocketbase(import.meta.env.PUBLIC_URL)
|
||||
export default client;
|
||||
// export const client = new Pocketbase("http://localhost:8080")
|
Loading…
x
Reference in New Issue
Block a user