Public
Versions
- Open: VersionChanges from v31 to v32+1-0export const lichessTV = (async () => {const { Chess } = await import("npm:chess.js");const channels = await fetch("https://lichess.org/api/tv/channels");const games = await channels.json();
const rapidGame = games["Rapid"];const game = await fetch(`https://lichess.org/game/export/${rapidGame.gameId}`,⦚ 12 unchanged lines ⦚export const lichessTV = (async () => {const { Chess } = await import("npm:chess.js");const channels = await fetch("https://lichess.org/api/tv/channels");const games = await channels.json();console.log(games);const rapidGame = games["Rapid"];const game = await fetch(`https://lichess.org/game/export/${rapidGame.gameId}`,⦚ 12 unchanged lines ⦚ - Open: VersionChanges from v30 to v31+5-2export const lichessTV = (async () => {
const channels = await fetch("https://lichess.org/api/tv/channels");const games = await channels.json();const rapidGame = games["Rapid"];⦚ 7 unchanged lines ⦚},);const fullPgn = await game.text();return fullPgn.trim().split("\n").at(-1);})();export const lichessTV = (async () => {const { Chess } = await import("npm:chess.js");const channels = await fetch("https://lichess.org/api/tv/channels");const games = await channels.json();const rapidGame = games["Rapid"];⦚ 7 unchanged lines ⦚},);const pgn = await game.text();const chess = new Chess();chess.loadPgn(pgn);return chess.ascii();})(); - Open: VersionChanges from v29 to v30+1-1⦚ 12 unchanged lines ⦚);const fullPgn = await game.text();
return fullPgn.trim().split("\n");})();⦚ 12 unchanged lines ⦚);const fullPgn = await game.text();return fullPgn.trim().split("\n").at(-1);})(); - Open: VersionChanges from v28 to v29+1-1⦚ 12 unchanged lines ⦚);const fullPgn = await game.text();
return fullPgn.split("\n");})();⦚ 12 unchanged lines ⦚);const fullPgn = await game.text();return fullPgn.trim().split("\n");})(); - Open: VersionChanges from v27 to v28+1-2⦚ 12 unchanged lines ⦚);const fullPgn = await game.text();
const pgn = fullPgn.split("\n").slice(-3);return pgn;})();⦚ 12 unchanged lines ⦚);const fullPgn = await game.text();return fullPgn.split("\n");})(); - Open: VersionChanges from v26 to v27+1-1⦚ 12 unchanged lines ⦚);const fullPgn = await game.text();
const pgn = fullPgn.split("\n").slice(-2);return pgn;})();⦚ 12 unchanged lines ⦚);const fullPgn = await game.text();const pgn = fullPgn.split("\n").slice(-3);return pgn;})(); - Open: VersionChanges from v25 to v26+1-1⦚ 12 unchanged lines ⦚);const fullPgn = await game.text();
const pgn = fullPgn.split("\n").slice(-1);return pgn;})();⦚ 12 unchanged lines ⦚);const fullPgn = await game.text();const pgn = fullPgn.split("\n").slice(-2);return pgn;})(); - Open: VersionChanges from v24 to v25+1-0⦚ 13 unchanged lines ⦚const fullPgn = await game.text();const pgn = fullPgn.split("\n").slice(-1);})();⦚ 13 unchanged lines ⦚const fullPgn = await game.text();const pgn = fullPgn.split("\n").slice(-1);return pgn;})();
- Open: Version+16-0export const lichessTV = (async () => {const channels = await fetch("https://lichess.org/api/tv/channels");const games = await channels.json();const rapidGame = games["Rapid"];const game = await fetch(`https://lichess.org/game/export/${rapidGame.gameId}`,{headers: {// Doesn't seem to return json"content-type": "application/json",},},);const fullPgn = await game.text();const pgn = fullPgn.split("\n").slice(-1);})();
Updated: October 23, 2023