Installation
π© Prerequisites
Before you begin, ensure your development environment meets the following requirements:
PHP Version: 8.2 or higher
Composer
One of the Cycle ORM adapters:
spiral/cycle-bridgeofficial Cycle ORM adapter for the Spiral Frameworkyiisoft/yii-cycleβ official Cycle ORM adapter for the Yii 3wayofdev/laravel-cycle-orm-adapterβ package managed by @wayofdev for the Laravel 10.x or higher.
πΏ Installation
The preferred way to install this package is through Composer.
composer require cycle/active-recordAfter package install you need to, optionally, register bootloader / service-provider in your application.
π§ Framework-Specific Configuration
β Spiral Framework
If you are installing the package on the Spiral Framework with the spiral-packages/discoverer package, then you don't need to register Bootloader by yourself. It will be registered automatically.
Otherwise, update the Bootloader list in your application configuration:
For more information about bootloaders, refer to the Spiral Framework documentation.
β Laravel
If you are using Laravel, then you don't need to register service-provider by yourself. It will be registered automatically.
β Yii 3
For configuration instructions refer to yii-cycle installation guide.
β Other Frameworks
This package uses PSR-11 compatible container to resolve dependencies. After container initialization you need to pass container instance to the static facade:
π§ Verifying Installation
To verify that Cycle Active Record has been installed correctly, you can create a simple entity and try to use it. If no errors occur, the installation was successful.
Last updated