Download the PHP package qklin/laravel-auto-router without Composer
On this page you can find all versions of the php package qklin/laravel-auto-router. It is possible to download/install these versions without Composer. Possible dependencies are resolved automatically.
Please rate this library. Is it a good library?
Informations about the package laravel-auto-router
Laravel/Lumen AutoRouter
Laravel/Lumen 注解路由自动加载和中间件自动注入
Table of Contents
- How
- Usage
How
Install with Composer:
Use simply:
Usage
目前支持的注解
- arRouter: 可直接配置方法携带后缀控制中间件
- arMethod: POST|GET|PUT|...
- arOnlyInisde: 路由必须inside开头
路由自动注入使用
- api必须【bapi】前缀。like:HotKeys => hot_keys
- 路径包含驼峰目录以【_】分隔。like:HotKeys => hot_keys
- 方法包含【.】的目录以【_】分隔。like:V1.0 => v1_0
- 方法包含驼峰以【-】分隔。like:getListsO => get-list-o
控制器方法添加注解配置案例
wptRouter注解配置说明
- O:Operate 操作 自动注入节流中间件
- L:Look 查看 自动移除节流中间件[如果存在]
- I:Inside 内网 自动注入内网中间件,且放置最前[如果不存在],自动剔除token中间件
- N:NotAuth 无需授权,公开api,自动移除token中间件[如果存在]
- V:validate 请求验证,自动移除请求验证中间件[如果不存在]
- X:checkSign 请求验签
- 如果都不存在,默认根据route.php配置走
配置route.conf
laravel版本在Application可以注入configure方法
All versions of laravel-auto-router with dependencies
PHP Build Version
Package Version
Requires
php Version
^7.0
The package qklin/laravel-auto-router contains the following files
Loading the files please wait ....