Question

i am working in vim and when i make js with modules then it not shown any tag.

and when i make this file with Class then it will show in taglist all things like below

Class

Method

Function

variables

and etc

like my module code like something in which Tagbar not working

var ENQUIRY = (function(){
      var enquiryData = {}, 
          tabTitleObj = {}, 
          screenData = {}, 
          tabContainer = $("<ul></ul>"),
          enquiryEntity = {}, 
          entityName = 'Incident',
          element = "", 
          completedEnquiryTabs = 0,
          dialogTitle = "", 
          editElement = "", 
          yesElement = " ",
          noElement = "<a href='#' class=' cancelImg' style='display:none' ><span >Cancel</span></a>";
          })();

and in normal mode it will like like below an Tagbar show this variable in Tagbar list

 var enquiryData = {}, 
              tabTitleObj = {}, 
              screenData = {}, 
              tabContainer = $("<ul></ul>"),
              enquiryEntity = {}, 
              entityName = 'Incident',
              element = "", 
              completedEnquiryTabs = 0,
              dialogTitle = "", 
              editElement = "", 
              yesElement = " ",
              noElement = "<a href='#' class=' cancelImg' style='display:none' ><span >Cancel</span></a>";

please help me to set Tagbar for modular JavaScript.

Was it helpful?

Solution

TagBar doesn't index your code: it delegates the job to an external program like exuberant ctags or jsctags. Correctly indexing your code is thus not a TagBar problem but a ctags/jsctags problem.

If you need help with either of those you'll have to ask another, more precise, question. If possible written in a better english. Or search this site because the topic has been discused many times before.

Licensed under: CC-BY-SA with attribution
Not affiliated with StackOverflow
scroll top