Search code examples
autocompletephpstormlaravel-5.3

Method 'create' not found in class Illuminate\Support\Facades\Schema


I'm using Laravel 5.3, in PhpStorm there is error under the method 'create' and many other methods. I tried all the ide_helpers but nothing resolved it

enter image description here

is there anyway to resolve this and the autocomplete?


Solution

  • I found the answer the problem was with the use lines :

    use Illuminate\Support\Facades\Schema;
    use Illuminate\Database\Schema\Blueprint;
    use Illuminate\Database\Migrations\Migration;
    

    first line should be replaced with:

    use Schema;