An open API service indexing awesome lists of open source software.

https://github.com/lainq/fen-rs

A simple and goofy library used to convert(and verify?) Forsyth-Edwards Notation in chess to board and vice-versa
https://github.com/lainq/fen-rs

c chess fen forsyth-edwards-notation

Last synced: about 2 months ago
JSON representation

A simple and goofy library used to convert(and verify?) Forsyth-Edwards Notation in chess to board and vice-versa

Awesome Lists containing this project

README

          

# Fenrs

A simple library used to parse Forsyth-Edwards Notation in chess.

```rs
use fenrs::Fen;

fn main() {
let notation = "rnbqkbnr/pppppppp/8/8/8/8/PPPPPPPP/RNBQKBNR w KQkq - 0 1";
let fen_obj = Fen::parse(&notation);
let back_to_notation = fen_obj.to_string();
}
```

## Documentation

The library only exposes a handful of structs and functions.
The usage is documented below

```rs
impl Fen {
// ...
fn parse>(notation: T) -> Result;
}

impl ToString for Fen {
fn to_string(&self) -> String;
}
```