G
G
Governor2020-05-23 07:04:39
phpstorm
Governor, 2020-05-23 07:04:39

Why doesn't PhpStorm see query builder snippets in models?

If you get a constructor object like this:
DB::table('articles')then you can list the methods of the Builder object (constructor), but if you use models, the same constructor methods are available, but there are no hints.

5ec8a09945086923344040.png
In the picture, Spanish the Tag model, and the constructor method are underlined because not found, but everything works.

Why is this happening and is it possible to include Builder hints in models?

I am using laravel 5.8

Answer the question

In order to leave comments, you need to log in

1 answer(s)
N
netrox, 2020-05-25
@netrox

Try https://github.com/barryvdh/laravel-ide-helper

Didn't find what you were looking for?

Ask your question

Ask a Question

731 491 924 answers to any question