Ecosyste.ms: Awesome

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

Awesome Lists | Featured Topics | Projects

https://github.com/kritzcreek/motoko-regex

Simple Regexes for Motoko
https://github.com/kritzcreek/motoko-regex

Last synced: about 2 months ago
JSON representation

Simple Regexes for Motoko

Awesome Lists containing this project

README

        

# motoko-regex

Simple regex matching for Motoko Text.

This project is in its very early stages and primarily serves as an example
of how to structure a Motoko library.

## Example
```motoko
import Regex "mo:regex/Regex";

assert(Regex.test(#rep(#seq(#char('A'), #char('B'))), "ABABABABAB"));
assert(not Regex.test(#rep(#seq(#char('A'), #char('B'))), "ABA"));
```

## Building

- Install [`vessel`](https://github.com/dfinity/vessel)
- Run `make check`, `make test`, or `make docs`