Download the PHP
package fremail/lumen-nested-route-groups without Composer
On this page you can find all versions of the php package
fremail/lumen-nested-route-groups. It is possible to download/install
these versions without Composer. Possible dependencies are resolved
automatically.
Vendor fremail Package lumen-nested-route-groups Short Description Extends a lumen application for using nested route groups. In addition to the groups it's possible to use any() and match() methods. License
MIT
After the download, you have to make one include require_once('vendor/autoload.php');. After that you have to import the classes with use statements.
Example:
If you use only one package a project is not needed. But if you use more then one package, without a project it is not possible to import the classes with use statements.
In general, it is recommended to use always a project to download your libraries. In an application normally there is more than one library needed.
Some PHP packages are not free to download and because of that hosted in private repositories.
In this case some credentials are needed to access such packages.
Please use the auth.json textarea to insert credentials, if a package is coming from a private repository.
You can look here for more information.
Some hosting areas are not accessible by a terminal or SSH. Then it is not possible to use Composer.
To use Composer is sometimes complicated. Especially for beginners.
Composer needs much resources. Sometimes they are not available on a simple webspace.
If you are using private repositories you don't need to share your credentials. You can set up everything on our site and then you provide a simple download link to your team member.
Simplify your Composer build process. Use our own command line tool to download the vendor folder as binary. This makes your build process faster and you don't need to expose your credentials for private repositories.
Informations about the package lumen-nested-route-groups
Changelog
v.1.1.0 Add $app->any() and $app->match() methods (no breaking changes)
Lumen nested route groups
Extends a lumen application for using nested route groups.
Lumen already uses a group in bootstrap/app.php, that is why you can't use another groups in app/Http/routes.php. This lib removes the restriction.
How to install (steps)
1. Install using Composer
2. Required changes in bootstrap/app.php
Change initialization of Lumen Application class to initialization of Lumen Nested Route Groups Application class in bootstrap/app.php.
Before:
After:
After these simple steps you can use nested route groups in your application!
Additional namespaces configuration
By default this lib uses nested namespace (Laravel style), but you can determine to use full namespaces instead (Lumen style).
Steps for using full namespaces:
Create config directory if you don't have one in the project root.
Copy NestedRouteGroups.php from vendor/fremail/lumen-nested-route-groups/config folder to the created config dir in the root.
Open the config/NestedRouteGroups.php file and set 'namespace' value to 'full'.
Add this line to your bootstrap/app.php: $app->configure('NestedRouteGroups');
Any() and Match() methods
Do you like any() and match() methods on Laravel? I love them! That's why I added supporting them on Lumen.
The syntax is the same as for Laravel:
Where
$methods - an array of methods. Example: ['get', 'post', 'delete']. $uri and $action are the same as on other methods
Here are $uri and $method are the same as on other methods like $app->get(...) etc.
Example of using this lib
This is an example of app/Http/routes.php
All versions of lumen-nested-route-groups with dependencies
Composer command for our command line client (download client)This client runs in each environment. You don't need a specific PHP version etc. The first 20 API calls are free.Standard composer command
The package fremail/lumen-nested-route-groups contains the following files
Loading the files please wait ....
Loading please wait ...
Before you can download the PHP files, the dependencies should be resolved. This can take some minutes. Please be patient.