Skip to content
New issue

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

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

Already on GitHub? # to your account

New routing system #186

Open
arctic-hen7 opened this issue Sep 2, 2022 · 0 comments
Open

New routing system #186

arctic-hen7 opened this issue Sep 2, 2022 · 0 comments
Labels
author-willing-to-impl The author of this issue is willing to try to implement the solution themselves. C-enhancement Category: enhancement tribble-reported This issue was reported through Tribble.

Comments

@arctic-hen7
Copy link
Member

This issue is requesting an enhancement to Perseus. Details of the scope will be available in issue labels.
The user described the problem related to this request as follows:

Right now, Perseus' routing system is good, but not good enough. In particular, I made the decision early on to not embrace the flexibility of the de facto routing paradigm: support for statements like /user/<param>/blah/<..param>. While achieving the same thing is possible in Perseus using incremental generation, it's far from easy.

The user described the issue as follows:

Perseus should support parameter-based routing through template names. Specifically, <param> should be interpreted as single path component that can vary, and <..param>/<param..> should be interpreted as a series of path components (like incremental generation works today). This would be very similar to the way Sycamore's router handles routing, though integrated with Perseus' incremental generation and broader state management systems. This will be complex, but not too difficult I don't think --- the only things that will need to change are possibly the render config format (file that tells Perseus how routes work in an app), and the routing logic. Right now, the routing logic is surprisingly simple, and this would probably mean some fundamental changes to it, but a lot of this could be based on Sycamore's routing systems. (I may even end up using them under the hood, as we used to in v0.1.0.)

  • The author is willing to attempt an implementation: true
Tribble internal data

dHJpYmJsZS1yZXBvcnRlZCxDLWVuaGFuY2VtZW50LGF1dGhvci13aWxsaW5nLXRvLWltcGw=

@github-actions github-actions bot added author-willing-to-impl The author of this issue is willing to try to implement the solution themselves. C-enhancement Category: enhancement tribble-reported This issue was reported through Tribble. labels Sep 2, 2022
# for free to join this conversation on GitHub. Already have an account? # to comment
Labels
author-willing-to-impl The author of this issue is willing to try to implement the solution themselves. C-enhancement Category: enhancement tribble-reported This issue was reported through Tribble.
Projects
None yet
Development

No branches or pull requests

1 participant