-
Notifications
You must be signed in to change notification settings - Fork 2.9k
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
URLPattern #2286
Comments
URLPattern is designed to be slow, so we aren't going to support this officially unless it becomes a web standard (WICG != W3C). You can use JS polyfills until then |
is it not a web standard ? link |
Please reconsider this. Make it an optional import and allow us to opt into using it if we are willing to accept the performance hit. |
I would like to make http server with bun. Here: https://bun.sh/guides/http/server only trivial path matching is demonstrated. Then what is bun proposal for that? |
Routing with regexp is painful and should be abandoned |
It is great feature for web but not so for server-side |
nice to have!!! |
Currently blocking the use of cross-runtime fetch mocks like @c4spar/mock-fetch. |
NodeJS just merged support for URLPattern nodejs/node#40844. If Bun wants full Node compatibility, implementing URLPattern seems unavoidable now. |
Safari shipped URLPattern this week as well, and URLPattern made it on the Interop 2025 list. |
nodejs ship it too but i guess this feature not so important because it slow by design and etc |
We use it for routing, as a polyfill (which is 1000 times slower). I personally don't get how you people call some implementation "slow" without even asking how much calls to that function will be made. In my view LLMs are slow. And all pattern matching algorithms, even the most ineffecient, are super fast 😅 |
Why u need this? Also https://en.m.wikipedia.org/wiki/ReDoS Radix-tree based routers is more fine |
What is the problem this feature would solve?
https://developer.mozilla.org/en-US/docs/Web/API/URLPattern
What is the feature you are proposing to solve the problem?
Although this is an experimental function, it is undoubtedly very practical for bun routing, and deno has already implemented it, so we can't live without it.
What alternatives have you considered?
No response
The text was updated successfully, but these errors were encountered: