You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
if the editor has a line like {{anything}} {{fo and the cursor is at the end, the auto completions are not shown even though it should be captured by the regex in the code (/\{\{.*?/gat least since there is an explicit global flag)
The auto completions are not shown for any matching occurrences after the first one
Screen.Recording.2025-01-22.at.10.19.53.PM.mov
The text was updated successfully, but these errors were encountered:
If there is a way to achieve this by fixing my code for generating the autoCompletions feel free to point that out, but I thought this is a bug and so have raised a PR for the same
I don't think complicating the semantics of this method is a good idea. Regexps are messy, and they won't work in all situations. But there's no real reason the updated behavior is more obvious than the current behavior, and that kind of hidden cleverness will trip people up.
I think if you use /\{\{([^{]|\{[^{])*$/ instead, you should get the match you're looking for.
Here's a
demo.ts
file to help reproduce the bug:if the editor has a line like
{{anything}} {{fo
and the cursor is at the end, the auto completions are not shown even though it should be captured by the regex in the code (/\{\{.*?/g
at least since there is an explicit global flag)The auto completions are not shown for any matching occurrences after the first one
Screen.Recording.2025-01-22.at.10.19.53.PM.mov
The text was updated successfully, but these errors were encountered: