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

Add SpaRouter #904

Merged
merged 2 commits into from
Apr 3, 2022
Merged

Add SpaRouter #904

merged 2 commits into from
Apr 3, 2022

Conversation

davidpdrsn
Copy link
Member

This adds SpaRouter to axum-extra. It makes it easy to get a routing setup common with single page apps.

Assets will be served using ServeDir from a nested path, unknown routes goes to some index file.

include!(concat!(
env!("CARGO_MANIFEST_DIR"),
"/../axum/src/test_helpers/test_client.rs"
));
Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Poor mans code sharing 🙃

@davidpdrsn davidpdrsn merged commit 405e3f8 into main Apr 3, 2022
@davidpdrsn davidpdrsn deleted the spa-routing branch April 3, 2022 16:29
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants