feat: 增加dify功能

1.  增加 dify 的 /app 和 /_next 代理,允许跨域请求
2. 增加 dify 的路由  /dify
3.  增加 dify 的可以隐藏侧边栏和导航栏
This commit is contained in:
Huangzhe
2025-04-22 17:14:54 +08:00
parent 84a4f8aed8
commit 8ace7fff7a
4 changed files with 137 additions and 0 deletions

View File

@@ -34,6 +34,28 @@ module.exports = {
errors: true
},
proxy: {
'/app': {
target: 'http://localhost:3000',
changeOrigin: true,
onProxyRes: (proxyRes, req, res) => {
delete proxyRes.headers['x-frame-options'];
},
pathRewrite: {
// '^/app': '/'
},
logLevel: 'debug'
},
'/_next': {
target: 'http://localhost:3000',
changeOrigin: true,
onProxyRes: (proxyRes, req, res) => {
delete proxyRes.headers['x-frame-options'];
},
pathRewrite: {
// '^/_next': '/'
},
logLevel: 'debug'
},
'/api': {
target: process.env.VUE_APP_ADMIN,
changeOrigin: true,