This package is not maintained now
Trait for create image thumbs for models via InterventionImage.
- Install using composer (run in your terminal):
composer require johan-code/image-thumbs
- Publish (run in your terminal):
php artisan vendor:publish --provider="JohanCode\ImageThumbs\ServiceProvider"
- Set name of disk for uploading in
/config/image-thumbs.php
:
return [
'disk_name' => 'public'
];
- Make sure the disk for uploading exist and available in public.
Example config /config/filesystems.php
'disks' => [
...
'public' => [
'driver' => 'local',
'root' => storage_path('app/public'),
'url' => '/storage',
],
...
],
Use laravel command for create symlink (run in your terminal):
php artisan storage:link
Add service provider in config/app.php
:
'providers' => [
...
JohanCode\ImageThumbs\ServiceProvider::class,
...
]
... and follow main instruction.