Use VIM omnicomplete for javascript with ctags

I have been using vim / gvim for 4 months now and now I have found a way to use it. My tag file is generated very well, and here it is a simple line.

my.namespace.classname / path / to / file.js / ^ my.namespace.classname = function (first_arg, $ /; "f

Here is an example of what I need for omnicomplete:

my.namespace.cla <- omnicomplete list with all class names in my.namespace

The above is the key to my problem, because it looks like omnicomplete is only looking for the namespace without including "my". in front of her. Therefore, I see another element in the omnicomplete list, and not in my class name.

However, if I type: tag my.namespace.classname, for example, gvim opens the correct file in the correct position.

What is wrong and how can I make it work?

+3
source share
1 answer

I noticed that a lot of omnicomplete is not well developed. I used php omnicomplete and had to log in and configure it to make it work correctly. I recommend you download omnicomplete for javascript. Then add it to your plugins directory. Then make changes until he does what you want.

Sorry, I could no longer help, but at least you will not be left without an answer.

+1
source

Source: https://habr.com/ru/post/1737344/


All Articles