reflex icon indicating copy to clipboard operation
reflex copied to clipboard

Get page route using a name

Open kasun opened this issue 2 years ago β€’ 0 comments

It would be really useful if we could supply a name when adding pages and then get a page URL using the name.

ex

app = pc.App()
app.add_page(about, router="/route", name="about-page")

# inside state
self.reverse_page_route("about-page")

If this approach is correct I can work on a PR for this.

kasun avatar Apr 06 '23 12:04 kasun