I want to implement JQL autocomplete functionality exactly like we have have on JIRA in my Angular application. I am able to get the autocomplete and suggestion data that is provided by JIRA’s rest API but i am not able to give suggestions like JIRA provides on it’s UI.
These APIs dump all the data that is required for suggesting next values to user. But the issue we are facing is properly parsing the string that user has entered. To suggest the next possible value we must map the existing tokens that user has entered already with jql fields, operators, values etc. which is a difficult as Jira JQL does not have any consistent delimiters.
To resolve above issue, I have come across “@atlassianlabs/jql-autocomplete - npm” this package to get autocomplete suggestions as it already using a JQL parser. But the issue with this package is that it does not have all the possible suggestions because I may need to suggest some custom fields as well that I have configured on my JIRA.
So I want to have some custom fields as well in suggestion values. How can I solve this problem ?
Also can anyone please help me to understand proper usage of this package so that I can extend this as per my needs ?