2017 © Pedro Peláez
 

library silex-router-provider

A simple router provider to Silex with YAML

image

mrprompt/silex-router-provider

A simple router provider to Silex with YAML

  • Friday, October 21, 2016
  • by mrprompt
  • Repository
  • 2 Watchers
  • 3 Stars
  • 965 Installations
  • PHP
  • 1 Dependents
  • 0 Suggesters
  • 2 Forks
  • 0 Open issues
  • 2 Versions
  • 0 % Grown

The README.md

Silex Router Provider

Build Status Code Climate Test Coverage Issue Count SensioLabsInsight Dependency Status Codacy Badge, (*1)

Define routes for application with YAML files., (*2)

Install

composer require mrprompt/silex-router-provider

Usage

use SilexFriends\Router\Router as RouterServiceProvider;

$app->register(new RouterServiceProvider(__DIR__ . DS . 'config' . DS . 'routes' . DS . 'routes.yml'));

Configuration files, (*3)

# routes.yml
# http://symfony.com/doc/current/components/routing/introduction.html
home:
    path: /
    defaults: { _controller: 'Controller\Home::get' }
    methods: [GET]

user:
    prefix: /user
    resource: routes.user.yml
# routes.user.yml
# http://symfony.com/doc/current/components/routing/introduction.html
user.home:
    path: /
    defaults: { _controller: 'Controller\User::get' }
    methods: [GET]

Testing

Just run phpunit without parameters, (*4)

phpunit

The Versions

21/10 2016

dev-master

9999999-dev

A simple router provider to Silex with YAML

  Sources   Download

MIT

The Requires

 

The Development Requires

10/10 2015

dev-develop

dev-develop

A simple router provider to Silex with YAML

  Sources   Download

MIT

The Requires

 

The Development Requires