Skip to content
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

Better 404 handling in isomorphic app #129

Open
mathiversen opened this issue Jul 18, 2019 · 2 comments
Open

Better 404 handling in isomorphic app #129

mathiversen opened this issue Jul 18, 2019 · 2 comments
Labels
good first issue Good for newcomers

Comments

@mathiversen
Copy link

mathiversen commented Jul 18, 2019

  • There seems to be a bug when navigating to the catch_all route but not contributors, ex. localhost:7878/test. The current implementation panics using both rocket and actix as server.
  • Rocket currently has 404 for unknown routes and this should be added to the actix example as well.
@chinedufn
Copy link
Owner

Ah thanks for pointing this out!

@chinedufn chinedufn added the good first issue Good for newcomers label Jul 28, 2019
@AxelNilsson
Copy link

AxelNilsson commented Jan 18, 2021

Here's an example of what I did using the isomorphic example.

lib.rs

impl App {
    pub fn render(&self) -> VirtualNode {
        match self.router.view(self.store.borrow().path()) {
            Some(route) => route,
            None => NotFoundView::new().render(),
        }
    }
}

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
good first issue Good for newcomers
Projects
None yet
Development

No branches or pull requests

3 participants