Ecosyste.ms: Awesome
An open API service indexing awesome lists of open source software.
https://github.com/imandra-ai/reasonml-tic-tac-toe
https://github.com/imandra-ai/reasonml-tic-tac-toe
formal-methods formal-verification imandra ocaml react reasonml
Last synced: 3 months ago
JSON representation
- Host: GitHub
- URL: https://github.com/imandra-ai/reasonml-tic-tac-toe
- Owner: imandra-ai
- Created: 2018-08-30T16:43:49.000Z (over 6 years ago)
- Default Branch: master
- Last Pushed: 2023-01-07T15:01:16.000Z (about 2 years ago)
- Last Synced: 2024-04-09T15:30:02.494Z (10 months ago)
- Topics: formal-methods, formal-verification, imandra, ocaml, react, reasonml
- Language: Reason
- Homepage: https://www.imandra.ai
- Size: 2.92 MB
- Stars: 19
- Watchers: 13
- Forks: 1
- Open Issues: 10
-
Metadata Files:
- Readme: README.md
Awesome Lists containing this project
README
# ReasonML Tic Tac Toe with Imandra
![Imandra](img/imandra_raas_logo.svg "Imandra")
This repo contains a ReasonReact app containing a game of Tic Tac Toe. The core logic of the game has been checked with some verification statements using [Imandra](https://www.imandra.ai).
See https://docs.imandra.ai/imandra-docs/notebooks/reasonml-tic-tac-toe/ for a walk through of the model, and explanation of the `verify` and `instance` comments throughout the file `src/TicTacToeLogic.re`.
See https://docs.imandra.ai/reasonml-tic-tac-toe/ for the built example.
## Run Project
You'll need a docker image with `imandra-extract` in it pre-pulled to convert the Imandra source file `src/TicTacToeLogic.ire` to regular OCaml so it can be compiled with bucklescript (the conversion is done using bucklescript generators, see `bsconfig.json`):
```sh
docker pull imandra/imandra-client-switch
``````sh
npm install
npm start
# in another tab
npm run parcel
```Then visit http://localhost:1234/index.html or http://localhost:1234/index-initial.html for the version of the model that contains the deliberate bug.
## Build for Production
```sh
npm run build
npm run parcel:production
```This will replace the development artifact with an optimized version.
To deploy:
```sh
npm run deploy
```