https://github.com/lpil/gpxb
Last synced: 3 months ago
JSON representation
- Host: GitHub
- URL: https://github.com/lpil/gpxb
- Owner: lpil
- Created: 2024-07-14T18:22:20.000Z (almost 2 years ago)
- Default Branch: main
- Last Pushed: 2024-12-08T14:41:50.000Z (over 1 year ago)
- Last Synced: 2025-10-07T00:48:05.654Z (7 months ago)
- Language: Gleam
- Size: 13.7 KB
- Stars: 4
- Watchers: 1
- Forks: 0
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
- Changelog: CHANGELOG.md
Awesome Lists containing this project
README
# gpxb
A tiny GPX builder for Gleam.
[](https://hex.pm/packages/gpxb)
[](https://hexdocs.pm/gpxb/)
```sh
gleam add gpxb@1
```
```gleam
import gpxb.{Gpx, Waypoint, Coordinate}
import gleam/option.{Some, None}
import gleam/string_builder
pub fn main() {
Gpx(
metadata: None,
waypoints: [
Waypoint(
coordinate: Coordinate(latitude: 51.53845, longitude: 0.14236),
name: Some("Mother Black Cap"),
description: None,
time: None,
),
],
routes: [],
tracks: [],
)
|> gpxb.render
|> string_builder.to_string
|> io.println
}
```
```xml
Mother Black Cap
```
Further documentation can be found at .