2

I'm working with a custom build framework where the controllers reference and render the templates using a unique string with directory separators represented by colons.

Example: ->render('dir1:dir2:file');

I want to be able to use PhpStorm's navigation by declaration by Ctrl/Cmd clicking the template string, but I don't know how to set this up in PhpStorm so that these strings can be mapped to the directory structure and the file found and opened. I'm not finding what I need in the PhpStorm docs.

Has anyone done something like this before, is it even possible?

Note: "Navigate From Literal" plugin does not work in this case.

LazyOne
  • 158,824
  • 45
  • 388
  • 391
  • 1
    *"is it even possible"* Sure -- by writing custom plugin (like Symfony/Laravel/aforementioned "Navigate From Literal" plugins do, for example). You may look at their source if interested. An example: views navigation in Laravel plugin (where user can define custom namespace .. so physically such files will be located in some another folder). Similar in Symfony. There is no generic user-configurable/bundled functionality for that. – LazyOne Mar 09 '18 at 14:12
  • Thanks for the info. There's no easy way out, here. Time to learn plugin development. – Jonathan Eltgroth Mar 12 '18 at 18:26

0 Answers0