chiron / app
Chiron Application Example
Fund package maintenance!
ncou
Installs: 55
Dependents: 0
Suggesters: 0
Security: 0
Stars: 1
Watchers: 2
Forks: 0
Open Issues: 1
Type:project
Requires
- php: ^8.0 || ^8.1
- chiron/chiron: ^3.9
- chiron/debug: ^1.0
- chiron/fastroute-bridge: ^1.0
- chiron/logger: ^0.2
- chiron/response-creator: ^1.0
- chiron/sapi: ^1.0
- chiron/translator: ^1.0
- chiron/view: ^1.0
- chiron/webserver: ^1.0
- nyholm/psr7: ^1.5
- vlucas/phpdotenv: ^5.0
Requires (Dev)
- chiron/devtools: ^1.0
- chiron/testing: ^1.0
This package is auto-updated.
Last update: 2024-12-14 03:33:55 UTC
README
[Chiron Framework] is a light framework designed to allow developpers to quickly start a new console or web application.
This repository contain an App Skeletton intended to show the basic Chiron features. Your first step to build amazing projects !
Requirements
Make sure that your web server is configured with following PHP version and extensions:
- PHP >= 7.2
- intl PHP Extension
- mbstring PHP Extension
Installation
If you do not have Composer, you may install it by following the instructions at getcomposer.org.
You can then install this project template using the following command:
$ composer create-project chiron/app [my-app-name]
Replace [my-app-name] with the desired directory name for your new application.
Cloning
This section applies only if you cloned this repo with
git clone
, not when installed withcomposer create-project ...
.
Make sure to properly configure your app project after cloning this repository.
$ composer install # Install the projet composer dependencies $ bin/chiron dotenv:copy -d .env # Create the .env file at the root path $ bin/chiron dotenv:key -m .env # Update the security key in .env file $ bin/chiron package:discover # Auto-discover the module bootloaders
Web Server
You can launch a development web server to quickly test you application.
$ php -S localhost:8000 -t public/
or
$ bin/chiron serve
Now you should be able to access the application through the URL printed in the console.
Directory structure
The application template has the following structure:
config/ #Configuration files. docs/ #Documentation. public/ #Files publically accessible from the Internet. assets/ #Published assets. index.php #Entry script. resources/ #Application resources. assets/ #Asset bundle resources. layout/ #Layout view templates. view/ #View templates. runtime/ #Files generated during runtime. src/ #Application source code. Asset/ #Asset bundle definitions. Controller/ #Web controller classes. Provider/ #Providers that take configuration and configure services. tests/ #A set of Codeception tests for the application. vendor/ #Installed Composer packages.
Testing
To test an application:
$ ./vendor/bin/phpunit
or
$ composer phpunit
License
This package is open-sourced software licensed under the MIT license.