ncm2-phpactor
ncm2-phpactor copied to clipboard
Automatic class import.
The current develop branch for Phpactor now supports automatically importing classes upon completion with OmniComplete.

Would be great to implement this in NCM2 also.
The suggestion format now looks like:
{
"type":"class",
"name":"ProcessUtilsTest",
"short_description":"Symfony\\Component\\Process\\Tests\\ProcessUtilsTest",
"class_import":"Symfony\\Component\\Process\\Tests\\ProcessUtilsTest",
}
Where class_import is non-empty it can call the import_class RPC method.
Awesome.
Will look into this.
It should be part of the snippet support.
This feature depends on https://github.com/ncm2/ncm2/issues/67 It is still WIP
Hello @dantleech how did you manage to do that with OmniComplete
https://phpactor.readthedocs.io/en/master/vim-plugin/man.html
g:phpactorOmniAutoClassImport apparently -- it's been a long time since I use Phpactor over LSP now