lichess-org / chessground

Mobile/Web chess UI for lichess.org
https://lichess.org
GNU General Public License v3.0
1.04k stars 261 forks source link

Input arrows from the chessground api? #295

Closed michaperki closed 7 months ago

michaperki commented 7 months ago

Is it possible to present pre-arranged arrows to the user? Or is there a way to include them in the fen?

ie:

import { Chessboard } from "react-chessboard"; 

<Chessboard
        position={fen}
        arrows=???
 />
michaperki commented 7 months ago

I figured it out... thanks!

    <>
      <Chessboard
        position={fen}
        customArrows={[ ['a3', 'a5', 'red'], ['g1', 'f3'] ]}
      />