mirror of
https://gitee.com/java110/MicroCommunityWeb.git
synced 2026-02-24 21:59:12 +08:00
优化组件内容
This commit is contained in:
parent
369f503fb5
commit
9973fa546d
12
app.js
12
app.js
@ -16,6 +16,11 @@ app.set('views', path.join(__dirname, 'views'));
|
||||
app.set('view engine', 'jade');
|
||||
|
||||
app.use(logger('dev'));
|
||||
|
||||
app.use('/callComponent', createProxyMiddleware({
|
||||
target: 'http://192.168.0.104:8443', // 目标代理地址
|
||||
changeOrigin: true
|
||||
}));
|
||||
app.use(express.json());
|
||||
app.use(express.urlencoded({ extended: false }));
|
||||
app.use(cookieParser());
|
||||
@ -24,13 +29,6 @@ app.use(express.static(path.join(__dirname, 'public')));
|
||||
app.use('/', indexRouter);
|
||||
app.use('/users', usersRouter);
|
||||
|
||||
app.use('/callComponent', createProxyMiddleware({
|
||||
target: 'https://hc.demo.winqi.cn', // 目标代理地址
|
||||
changeOrigin: true,
|
||||
pathRewrite: {
|
||||
'^/callComponent': ''
|
||||
}
|
||||
}));
|
||||
|
||||
// catch 404 and forward to error handler
|
||||
app.use(function(req, res, next) {
|
||||
|
||||
Some files were not shown because too many files have changed in this diff Show More
Loading…
Reference in New Issue
Block a user