[YOUR_FRAMEWORK] codebase containing real world examples (CRUD, auth, advanced patterns, etc) that adheres to the RealWorld spec and API.
This codebase was created to demonstrate a fully fledged fullstack application built with Tide including CRUD operations, authentication, routing, pagination, and more.
We've gone to great lengths to adhere to the Tide community styleguides & best practices.
For more information on how to this works with other frontends/backends, head over to the RealWorld repo.
This backend leverages rusts' tide framework for implementing the web app, and sqlite database managed as a single file. Simple configuration is available through .env file.
Install rust
# download rustup and install Rust
curl --proto '=https' --tlsv1.2 -sSf https://sh.rustup.rs | sh
Download and install sqlite
# for Ubuntu:
apt-get install sqlite3
Configure backend by editing .env file
Build and run backend
cargo run
You can run app with fresh database by setting DROP_DATABASE=1 in .env file. Database location and host and port are configurable as well.
Note: registering and logging in take some seconds because password hashing is CPU consuming.
Configure HOST=127.0.0.1 or delete HOST from .env and set HTTP_PORT=3000 and execute
cargo run
These tests do not cover http requests parsing, instead they introduce business logic testing steps by artificially forming middle layer server requests thus simulating local loop without involving tide framework. Execute
cargo test -- --nocapture