electricity_bill_calc_service/doc/routerSetting.md

13 lines
678 B
Markdown
Raw Blame History

This file contains ambiguous Unicode characters

This file contains Unicode characters that might be confused with other characters. If you think that this is intentional, you can safely ignore this warning. Use the Escape button to reveal them.

## fiber
#### fiber实例
- app是fiber创建的实例通常用app表示其中有可选配置选项
- BodyLimit 设置请求正文允许的最大大小默认为4 * 1024 * 1024
- EnablePrintRoutes 不打印框架自带日志默认false)
- EnableTrustedProxyCheck 禁用受信代理默认false)
- Prefork 预处理配置默认false)
- ErrorHandler 全局错误处理 默认false)
- JSONEncoder json编码 默认json.Marshal)
- JSONDecoder json解码 (默认json.Unmarshal)
- 。。。。。。。。(还有很多配置)
- Use中间件设置一个或者多个
- Group类似于gin框架中的路由分组