GitHub
Npm
Preparing search index...
The search index is not available
Nb2
Nb2
cors
Function cors
cors
(
opt
?
)
:
Middleware
Parameters
opt
:
{
credentials
?:
boolean
;
maxAge
?:
number
;
origin
?:
string
;
}
= {}
Optional
credentials
?:
boolean
跨域请求是否允许携带cookies、http认证信息 如果为true,则origin不能为*
Optional
max
Age
?:
number
预检请求的缓存时间,单位ms
Optional
origin
?:
string
Returns
Middleware
Settings
Member Visibility
Protected
Inherited
External
Theme
OS
Light
Dark
GitHub
Npm
Nb2
Loading...
跨域请求是否允许携带cookies、http认证信息 如果为true,则origin不能为*