From 8688bce4689385439c872f9acac2fc5dc50f0393 Mon Sep 17 00:00:00 2001 From: Sam Carlton Date: Fri, 20 Nov 2020 17:07:13 -0600 Subject: [PATCH] Use rawg url as View Link --- helpers/build-game-list.js | 9 ++++++++- 1 file changed, 8 insertions(+), 1 deletion(-) diff --git a/helpers/build-game-list.js b/helpers/build-game-list.js index 6e389ae..fe696f6 100644 --- a/helpers/build-game-list.js +++ b/helpers/build-game-list.js @@ -84,6 +84,8 @@ export default async function () { // Game already has entry if (gameIndex !== -1) { + // console.log('Existing Game', game) + gameList[gameIndex].reports.push(game) continue @@ -110,7 +112,12 @@ export default async function () { slug: 'games' }, content: '', - relatedLinks: [], + relatedLinks: [ + { + "href": `https://rawg.io/search?query=${encodeURIComponent(game.Games)}`, + "label": "View" + } + ], reports: [ game ]