860 B



slim 3 extend to MVC structure.

Some Feature :

  • Global config, Environment support
  • Language support
  • Command support
  • Twig template engine
  • Flash Messages
  • Monolog
  • Pimple Dependency Injection Container
  • Controller layer for MVC
  • RESTFul Controller
  • Model layer, database query builder.
  • Tracy Errors Handler(by whoops)


  • Use composer

edit composer.json

require add

"inhere/slim-extend": "dev-master",

run: composer update


generate class

support: model, command, controller

how to use:

php bin/console gen
php bin/console gen:model -h
  • a model
php bin/console gen:model name=rolePermission table=role_permission type=db fileds="id,int;name,string,名称;priority,int,级别;permissions,string,权限"

more see Document