定制 reiterus/microapi-core 二次开发

按需修改功能、优化性能、对接业务系统,提供一站式技术支持

邮箱:yvsm@zunyunkeji.com | QQ:316430983 | 微信:yvsm316

reiterus/microapi-core

最新稳定版本:1.3.3

Composer 安装命令:

composer create-project reiterus/microapi-core

包简介

MicroApi Core is an ultra-lightweight, tiny engine based on Symfony packages.

README 文档

README

MicroApi Core is an ultra-lightweight, tiny engine based on Symfony packages. It is intended for building small REST API applications. Since MicroApi is based on the Symfony architecture, it can be developed to any level of complexity if desired. Forming your application based on this engine, you will always be sure that there is nothing superfluous in your code.

Features of MicroApi Core out of the box:

  • all endpoints are public
  • loading all types of env files
  • use of attributes
  • only two configuration files
  • use autoload_runtime.php
  • minimum php version: 8.1
  • Docker
  • JSON response to an exception
  • Makefile
  • quality tools
    • PHP CS Fixer
    • PHPStan

Join the development of MicroApi!

Usage

It's very simple! Just run these two commands:

  • composer create-project reiterus/microapi-core folder && cd folder
  • make docker-start

That's all!
Now your API app is available at http://localhost:8008

Engine progress

Makefile commands

For the convenience of working with the project, there are several make-commands: local and for Docker.

See more...

Local

  • make phpunit: run ./vendor/phpunit/phpunit/phpunit
  • make phpfixer: run ./vendor/bin/php-cs-fixer fix
  • make phpstan: run ./vendor/bin/phpstan analyse
  • make server: run cd public/ && php -S 127.0.0.1:8008
  • make remover: run rm -rf var/ && rm -rf vendor/

Docker

  • make docker-start: run docker-compose up -d --build && docker-compose exec api composer install
  • make docker-restart: run rm -rf var/ && rm -rf vendor/ && docker-compose up -d --build && docker-compose exec api composer install
  • make docker-build: run docker-compose up -d --build
  • make docker-install: run docker-compose exec api composer install
  • make docker-down: run docker-compose down
  • make docker-rm: run docker rm $(docker ps -aq) -f
  • make docker-rmi: run docker rmi $(docker images -aq) -f

Installation

You can install the project in two ways

From packagist.org

composer create-project reiterus/microapi-core

From GitHub repository

{
 "repositories": [
  {
   "type": "vcs",
   "url": "https://github.com/reiterus/microapi-core.git"
  }
 ]
}

License

This library is released under the MIT license.

统计信息

  • 总下载量: 19
  • 月度下载量: 0
  • 日度下载量: 0
  • 收藏数: 10
  • 点击次数: 1
  • 依赖项目数: 0
  • 推荐数: 0

GitHub 信息

  • Stars: 7
  • Watchers: 1
  • Forks: 3
  • 开发语言: PHP

其他信息

  • 授权协议: MIT
  • 更新时间: 2023-04-05