Typehints and typerrors for "run" method #255
Closed
msnegurski
started this conversation in
Ideas
Replies: 2 comments
-
This is provided by the Laravel Idea plugin for anyone using PHPStorm. |
Beta Was this translation helpful? Give feedback.
0 replies
-
There is also an IDE helper package. I have currently no idea how we could implement that better in this package. |
Beta Was this translation helpful? Give feedback.
0 replies
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
-
Hey, would be great if "run" method provided typehints and errors that are same as in "handle" method.
For example, for "handle" function
public function handle(string $query): array
would be great if "run" method requiredstring
input and had return type ofarray
.I don't know how feasable it is though. Tried to implement it in my project but with no success - PHP desparately lacks generics.
Beta Was this translation helpful? Give feedback.
All reactions