定制 chiron/chiron 二次开发

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

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

chiron/chiron

Composer 安装命令:

composer require chiron/chiron

包简介

Chiron is a PHP micro framework

README 文档

README

Build Status Coverage Status CodeCov

Latest Stable Version Total Downloads Monthly Downloads

StyleCI PHP-Eye PHPStan

Micro-Framework

Chiron is a PHP micro framework that helps you quickly write simple yet powerful web applications and APIs. All that is needed to get access to the Framework is to include the autoloader.

<?php
use \Psr\Http\Message\ServerRequestInterface as Request;
use \Psr\Http\Message\ResponseInterface as Response;

require_once __DIR__.'/../vendor/autoload.php';

$app = new Chiron\Application();
$app->get('/hello/[:name]', function (Request $request, Response $response, string $name) {
    $response->getBody()->write('Hello ' . $name);
    return $response;
});
$app->run();

Next we define a route to /hello/[:name] that matches for GET http requests. When the route matches, the function is executed and the return value is sent back to the client as an http response.

Installation

If you want to get started fast, use the Chiron Skeleton as a base by running this bash command :

$ composer create-project chiron/chiron-skeleton [my-app-name]

Replace [my-app-name] with the desired directory name for your new application.

You can then run it with PHP's built-in webserver:

$ cd [my-app-name]; php -S localhost:8080 -t public public/index.php

Or using the Composer shortcut :

$ composer start

If you want more flexibility, and install only the framework, use this Composer command instead:

$ composer require chiron/chiron

Description

About Chiron

Features

Motivation

Chiron was built with the purpose of understanding how major PHP frameworks operate under the hood. Most frameworks like Laravel implement techniques that can seem like "magic" unless you actually implement them yourself, an example being utilizing reflection API to plug in dependencies. Chiron has helped me so much with familarizing myself with quite a few advanced concepts in the PHP & OOP world.

Skeletons

App Type Current Status Install
chiron/app Latest Stable Version https://github.com/chironphp/app
chiron/app-cli Latest Stable Version https://github.com/chironphp/app-cli

License:

MIT License (MIT). Please see LICENSE for more information.

统计信息

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

GitHub 信息

  • Stars: 1
  • Watchers: 1
  • Forks: 0
  • 开发语言: PHP

其他信息

  • 授权协议: MIT
  • 更新时间: 2018-03-18

承接程序开发

PHP开发

VUE

Vue开发

前端开发

小程序开发

公众号开发

系统定制

数据库设计

云部署

网站建设

安全加固