<script>
import {Chess} from 'svelte-chess';
let moveNumber, turn, history;
</script>
<div style="max-width:512px;">
<Chess bind:moveNumber bind:turn bind:history/>
</div>
<p>
It's move {moveNumber}, with {turn=='w'?'White':'Black'} to move.
Moves played: {history?.join(' ')}.
</p>