-
Notifications
You must be signed in to change notification settings - Fork 7
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Allow using array for ignoreUnimportedSymbols #35
Comments
Thanks for bringing this up! I haven't personally used Laravel, but if I can get a list of all their global functions, I can easily add a built-in exception list in the same way I have for WordPress functions. Do you happen to have a list of them or know where I could find them? That said, I believe your main question is about supporting arrays in the Lastly, you mentioned seeing "Found unimported symbol 'Exception'." In general it's a good idea to specify a full path to the On the other hand, if you'd prefer to ignore that warning when you're already in the global namespace, you can use the |
I'm pretty new to Laravel but from my digging around the list can be found at https://github.com/laravel/framework/blob/7.x/src/Illuminate/Foundation/helpers.php |
I'm not sure that
I also forced |
Sorry for the confusion, when I said "if you'd prefer to ignore that warning when you're already in the global namespace, you can use the ignoreGlobalsWhenInGlobalScope configuration option to do that", I meant that that option would allow you to avoid the warning about
What's an example of the warnings you're seeing? The regular expression you have there should prevent warnings for |
Thanks for the screenshot! Your regular expression is Try changing it to |
Yes. It works now. I haven't taken the time to test the regex. I just assumed. My bad for copy/paste. Thank you for this! Keep up the good work! |
I started using Laravel and found the same problem. Global helpers raise an |
Many of laravel helper functions like
app(),
request() e.g. $credentials = request(['username', 'password']); and
build in throw new Exception(),
and some of self-created function etc.s are showing warning with
Found unimported symbol 'Exception'.
Found unimported symbol 'request'.
, So i need to add these function to inside of the rule config.
For now the writing format is like so
can it be able write as below or some other feature to be able to cover laravel helper functions and Exceptions functions etc;
The text was updated successfully, but these errors were encountered: