package
Version:
v0.6.2
Opens a new window with list of versions in this module.
Published: May 16, 2026
License: Apache-2.0
Opens a new window with license information.
Imports: 4
Opens a new window with list of imports.
Imported by: 0
Opens a new window with list of known importers.
Documentation
¶
GetAllowedOrigins exposes the configured origin list for logging.
IsEnabled reports whether the supplied CORS configuration is active.
Middleware 创建 CORS 中间件。
corsConfig 应已经过 corsv1.CORS.ApplyDefaults()(由业务方在
bootstrap.ScanSections 时自动完成),本函数不再回填默认值。
当 corsConfig 为 nil 或 Enable=false 时返回透传中间件。
Source Files
¶
Click to show internal directories.
Click to hide internal directories.