Skip to content

tomkyle/boilerplate-php

Repository files navigation

PHP Package Boilerplate

Packagist PHP version PHP Composer Software License

A template repository for PHP package.


Start new project

$ composer create-project tomkyle/boilerplate-php new-project  
$ cd new-project
$ composer install
$ npm install

Requirements and suggestions

PSR standard require suggest
PSR-3 Logger implementation psr/log Monolog Logger
PSR-6 Cache Implementation psr/cache Symfony Cache component
PSR-17 HTTP factory* implementation psr/http-factory nyholm/psr7
PSR-18 HTTP client psr/http-client Guzzle 7
$ composer require monolog/monolog
$ composer require symfony/cache
$ composer require nyholm/psr7
$ composer require guzzlehttp/guzzle

Development

Run npm update and watch the file system for PHP code changes. See package.json for a list of all watch and test tasks.

$ nmp run watch