Registry / orm / calebporzio-sushi

calebporzio-sushi

JSON →
library2.5.4phppackagistunverified

Eloquent's missing 'array' driver for using arrays as database tables.

composer require calebporzio/sushi
INSTALL
IMPORT
SIG · CALEBPORZIO-SUSHI
C
calebporzio-sushi
ormphpv2.5.4
harness data pending
Install & Compatibility
Where this runs

No compatibility data collected yet for this library.

Code
Verified usage

Verified import paths — ran on the pinned version, not inferred.

Sushi
use Sushi\Sushi;

Define an Eloquent model with inline array data

<?php use Sushi\Sushi; class User extends \Illuminate\Database\Eloquent\Model { use Sushi; protected $rows = [ ['id' => 1, 'name' => 'John'], ]; } $user = User::find(1);
Debug
Known issues
gotchaSushi models do not support relationships with database-backed models by default.
fix
Use the 'sushi' database connection or manually define relationships.
affects: *
Upgrade
Version history
2.5.4latest on Packagist
Audit
Dependencies

No dependency data recorded yet.

Agent activity
41 hits · last 30 days
node
38
OpenAI (training)
1
Resources
calebporzio-sushi — pip install calebporzio-sushi · libregistry