Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

VSCodeVim seems don't support full text matching #4736

Closed
oldmtn opened this issue Apr 14, 2020 · 3 comments
Closed

VSCodeVim seems don't support full text matching #4736

oldmtn opened this issue Apr 14, 2020 · 3 comments

Comments

@oldmtn
Copy link

oldmtn commented Apr 14, 2020

e.g.
If I want to search a text 'localStream', I will type a search word like:
/<localStream>
but it don't work.

@J-Fields
Copy link
Member

I assume this is a difference between vim and JS regex? #3996

@sql-koala
Copy link
Contributor

Hi, yes this it is.
The js regex would be: \blocalStream\b, (\b is a word boundary, which is \< or \> in vim).

@oldmtn
But you can use the js regex with vims search.

@J-Fields
I was a bit suprised to see that vscodevim directly "pastes" the vim pattern into a js regex (more or less). It would be possible to "translate" a vim pattern to js regex, in cases like this ( where js regex offers a functional equivalent, just with different syntax).
VsVim does this,but it is some amount of work.

@oldmtn
Copy link
Author

oldmtn commented Apr 30, 2020

Hi, yes this it is.
The js regex would be: \blocalStream\b, (\b is a word boundary, which is < or > in vim).

@oldmtn
But you can use the js regex with vims search.

@J-Fields
I was a bit suprised to see that vscodevim directly "pastes" the vim pattern into a js regex (more or less). It would be possible to "translate" a vim pattern to js regex, in cases like this ( where js regex offers a functional equivalent, just with different syntax).
VsVim does this,but it is some amount of work.

Thanks for you help.
'\blocalStream\b' is work for me.

@oldmtn oldmtn closed this as completed Apr 30, 2020
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

3 participants