Limit AngularJS filter search criteria to initials and endings

Asked 2 years ago, Updated 2 years ago, 48 views

Questions about AngularJS filtering capabilities.

"12345"
"23456"
"34567"
"45678"

"If there is a string ""45"", everything will get stuck if you enter ""45"", but
" Only "45678" will be displayed if only initials are searched.
Is it possible to set only 12345 to be displayed when searching only the end of a word?

I searched for it in my own way, but I couldn't find it, so I'll ask you a question.

angularjs

2022-09-30 17:34

1 Answers

Why don't you create a custom filter so that you can use regular expressions?

https://stackoverflow.com/questions/12046928/how-to-use-regex-with-ng-repeat-in-angularjs

How about the regex filter here?


2022-09-30 17:34

If you have any answers or tips


© 2024 OneMinuteCode. All rights reserved.