batch.com/headers-bundle
最新稳定版本:2.0.0
Composer 安装命令:
composer require batch.com/headers-bundle
包简介
A Symfony bundle to easily add headers to your responses.
README 文档
README
A Symfony bundle to ease the configuration of global response headers. Instead of creating a response listener to add custom headers, use a configuration file:
batch_headers: headers: # Apply a CSP on all the responses - Content-Security-Policy: default-src 'self' # Allow your API to be requested from all origins - name: Access-Control-Allow-Origin value: "*" condition: request.getPathInfo() matches '^/api' # Always cache images - name: Cache-Control value: max-age=31536000, public condition: response.headers.get('Content-Type') matches '^image/'
Installation
$ composer require batch.com/headers-bundle
Read the documentation for complete instructions.
Documentation
Read the documentation in src/Resources/doc/
统计信息
- 总下载量: 50.79k
- 月度下载量: 0
- 日度下载量: 0
- 收藏数: 0
- 点击次数: 1
- 依赖项目数: 0
- 推荐数: 0
其他信息
- 授权协议: MIT
- 更新时间: 2020-10-15