Navigate to Class

#13 Navigate to Class

navigation, class, fuzzy search

Press Cmd+O to invoke the 'Open Class' dialogue and start typing to find any class within your project.

This is a very quick and precise method of navigation and should not be overlooked.

Fuzzy Searching

If the search term returns too many results, you can use fuzzy searching to add to the search term and narrow down the number of results.

PhpStorm will identify any capital letters in the search term and try to associate those letters with classes named using CamelCasing.

As seen in the recording above, the HomepageController could be opened by searching for 'Homepage' or with fuzzy searching 'HomeCont'.

If this still returns too many results, the namespace can be included in the search term. The fully qualified class name from the example would be App\Http\Controllers\HomepageController, so you could try searching for 'Contr\Home' which would match the 'Controllers\HomepageController' portion of the class name, or even 'A\H\C\HC' to get a little creative.

Windows/Linux Keys

Press Ctrl+N to invoke the 'Open Class' dialogue.

Further Reading

Related Tips

Blog Comments powered by Disqus.