PHPStorm Laravel Not Finding Alias Class for Laravel Goutte

I installed this package and followed the readme instructions. However, when I put this in my HomeController:

$crawler = Goutte::request('GET', '');
$crawler->filter('.result__title .result__a')->each(function ($node) {
return view('welcome');

I got an error “Undefined class Goutte”. When I mouseover Goutte in phpstorm, it only gives me the option to create a new class, not import a facade.

I re-ran composer dump-autoload and that cleared it. Also php artisan ide-helper:generate.


Published by

Joel Gross

Joel Gross is the CEO of Coalition Technologies.