Skip to content
Projects
Groups
Snippets
Help
This project
Loading...
Sign in / Register
Toggle navigation
JuyuanPrimarySchool
Overview
Overview
Details
Activity
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Board
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
vue-project
JuyuanPrimarySchool
Commits
18641583
Commit
18641583
authored
Jul 20, 2021
by
zsh
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
添加apis
parent
e3672691
Hide whitespace changes
Inline
Side-by-side
Showing
3 changed files
with
33 additions
and
1 deletions
+33
-1
runner
runner
+1
-1
index.js
src/public/apis/index.js
+15
-0
proxy.js
src/public/apis/proxy.js
+17
-0
No files found.
runner
@
bede2605
Subproject commit
769217b0cf659737061a80d91e4bc6fe23f27816
Subproject commit
bede2605b1e5d42e9e7f861300e2c3a27eb03634
src/public/apis/index.js
0 → 100644
View file @
18641583
/**
* @file apis.js 接口存放
*/
;(
function
()
{
// 接口请求域名
window
.
domain
=
{
stg
:
''
,
// 测试环境域名
prd
:
''
// 生产环境域名
}
// 接口请求路径
window
.
apis
=
{
}
})()
src/public/apis/proxy.js
0 → 100644
View file @
18641583
/**
* @file apis/proxy 开发环境跨域配置
*/
module
.
exports
=
{
host
:
'127.0.0.1'
,
port
:
'8082'
,
// 自定义端口号
proxyTable
:
{
// Vue开发环境跨域配置
'/apis'
:
{
target
:
'http://test-a.com'
,
pathRewrite
:
{
'^/apis'
:
'/'
},
changeOrigin
:
true
// 是否跨域 - 开启代理, 在本地会创建一个虚拟服务端, 然后发送请求的数据, 并同时接收请求的数据, 这样服务端和服务端进行数据的交互就不会有跨域问题
}
}
}
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment