WasMyRoute is a web application that allows users to create, navigate and record their favorite trail routes and cycling routes. The application is designed to operate on web browsers and once it is loaded, can still be used to track and navigate without internet connection. The application can import tracks and export routes in GPX format.
In future, users can create an account and login to view their saved routes. Users can also view other users routes and save them to their account.
The project is a WebAssembly applicaton written in Rust. Install wasmyroute
by:
rustup target add wasm32-unknown-unknown
cargo install wasm-pack
cargo new --lib wasmyroute
Install trunk
and other required dependencies
cargo install --locked trunk
cargo install wasm-bindgen-cli
cargo add web-sys
cargo add log
To deploy this project
trunk serve
To run tests, run the following command:
cargo test
To run wasm-bindgen test, install cargo install wasm-bindgen-cli
and then run the following command:
wasm-pack test --safari
You will also need to open Safari window to see the result.
Or you can test under headless mode:
wasm-pack test --headless --firefox
Client: WebAssembly, Rust, Yew
- I learnt so much from him through his blog
Very useful OSM export resource - HOT Export Tool
Export by countries cities
Sketch GPX file - gpx.studio — the online GPX file editor
Script-like tools to fetch OSM - overpass turbo
brew install osmium-tool
Examples:
osmium fileinfo Cambridgeshire_UK.osm.pbf
osmium fileinfo -e Cambridgeshire_UK.osm.pbf
osmium show Cambridgeshire_UK.osm.pbf
osmium cat Cambridgeshire_UK.osm.pbf -o Cambridgeshire_UK.osm
osmium cat ukmap.osm -o ukmap.osm.pbf
Concatenate to stdout for other programs
osmium cat Cambridgeshire_UK.osm.pbf -f osm | cargo +nightly run
where -f
specified the output format