Tazim Tazvi
Tazim Tazvi

Reputation: 1

php artisan vendor:publish --provider="Maatwebsite\Excel\ExcelServiceProvider" BadMethodCallException

run "composer require maatwebsite/excel" in laravel-10 project for excel file but showed "Package phpoffice/phpexcel is abandoned, you should avoid using it. Use phpoffice/phpspreadsheet instead."

and then run "php artisan vendor:publish --provider="Maatwebsite\Excel\ExcelServiceProvider" --tag=config" but showing bad method.

i added "Maatwebsite\Excel\ExcelServiceProvider::class," provider in app.php and also "'Excel' => Maatwebsite\Excel\Facades\Excel::class",aliases.

anyone can help me out??

I tried composer update but it still shows "Package phpoffice/phpexcel is abandoned, you should avoid using it. Use phpoffice/phpspreadsheet instead."

I was expecting to successful installation of laravel excel

Upvotes: 0

Views: 634

Answers (1)

composer remove maatwebsite/excel

composer require psr/simple-cache:^1.0 maatwebsite/excel --ignore-platform-reqs --with-all-dependencies

php artisan vendor:publish --provider="Maatwebsite\Excel\ExcelServiceProvider"

working fine

Upvotes: 0

Related Questions