Hacker Newsnew | past | comments | ask | show | jobs | submitlogin

URLPattern can be plenty fast if you use them in a fast data structure, like a prefix tree as pointed out in that first link. And there's no reason why URLPattern can't do that.

So I went and made an implementation of URLPatternList that uses a prefix tree and is 20-30x faster than a linear scan for large lists of URLPatterns: https://github.com/justinfagnani/url-pattern-list



Guidelines | FAQ | Lists | API | Security | Legal | Apply to YC | Contact

Search: