jnjxp / urlhelper
Aura Router 的 URL 查看助手
0.1.0
2016-11-15 20:04 UTC
Requires
- aura/router: ^3.0
- psr/http-message: ~1.0
Requires (Dev)
This package is auto-updated.
Last update: 2024-08-26 08:11:22 UTC
README
Aura Router 的查看助手
<?php use Jnjxp\Urlhelper; // Pass an aura router container to the urlHelperContainer $urlHelperContainer = new UrlHelper\Container($routerContainer); // add the middleware to your stack to have the request injected // probably want to add it quite late $stack->middle($urlHelperContainer->getMiddleware()); // add the helper to aura html helpers $helpers->set('url', [$urlHelperContainer, 'getHelper']);