Skip to content

TakayukiInaba/laravel-excel-docs

 
 

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

85 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

home heroImage actionText actionLink features footer
true
/assets/img/logo-small.png
Read documentation →
/3.1/
title details
💪 Export to Excel.
Supercharge your Laravel collections or Blade views and export them directly to an Excel or CSV document. Exporting has never been so easy.
title details
🚀 Supercharged exports.
Export queries with automatic chunking for better performance. For even more superpowers, exports can also be queued.
title details
🔥 Supercharged imports.
Import workbooks and worksheets to Eloquent models with chunk reading and batch inserts! You can also queue every chunk of a file! Your entire import will happen in the background.
MIT Licensed | Powered by Maatwebsite

💡 Install the package via composer.

composer require maatwebsite/excel

💪 Create an export and import class.

php artisan make:export UsersExport --model=App\\User
php artisan make:import UsersImport --model=App\\User

🔥 Download your export and import your file.

<?php 

use App\Exports\UsersExport;
use App\Imports\UsersImport;
use Maatwebsite\Excel\Facades\Excel;
use App\Http\Controllers\Controller;

class UsersController extends Controller 
{
    public function export() 
    {
        return Excel::download(new UsersExport, 'users.xlsx');
    }
    
    public function import() 
    {
        return Excel::import(new UsersImport, 'users.xlsx');
    }
}

Releases

No releases published

Packages

No packages published

Languages

  • JavaScript 90.6%
  • CSS 9.4%