strip out set-cookie header in proxied request responses
This commit is contained in:
@@ -27,11 +27,21 @@ export default defineConfig({
|
|||||||
'/graphql': {
|
'/graphql': {
|
||||||
target: 'https://graphql.anilist.co',
|
target: 'https://graphql.anilist.co',
|
||||||
changeOrigin: true,
|
changeOrigin: true,
|
||||||
|
configure: (proxy, options) => {
|
||||||
|
proxy.on('proxyRes', proxyRes => {
|
||||||
|
delete proxyRes.headers['set-cookie'];
|
||||||
|
});
|
||||||
|
},
|
||||||
},
|
},
|
||||||
'^/mangaupdates/.*$': {
|
'^/mangaupdates/.*$': {
|
||||||
target: 'https://api.mangaupdates.com',
|
target: 'https://api.mangaupdates.com',
|
||||||
changeOrigin: true,
|
changeOrigin: true,
|
||||||
rewrite: (path) => path.replace(/^\/mangaupdates/, ''),
|
rewrite: (path) => path.replace(/^\/mangaupdates/, ''),
|
||||||
|
configure: (proxy, options) => {
|
||||||
|
proxy.on('proxyRes', proxyRes => {
|
||||||
|
delete proxyRes.headers['set-cookie'];
|
||||||
|
});
|
||||||
|
},
|
||||||
},
|
},
|
||||||
},
|
},
|
||||||
},
|
},
|
||||||
|
|||||||
Reference in New Issue
Block a user