Say I define a constant list as follows:
const SHOWS = {
'Game of Thrones': 'Game_of_Thrones',
'Modern Family': 'Modern_Family'
};
What I want to do is create a function that, when a user types in a string, recognizes if the input is either 'Game of Thrones' or 'Modern Family' and then replace it with the link to its wikipedia page (https://en.wikipedia.org/wiki/Modern_Family / https://en.wikipedia.org/wiki/Game_of_Thrones). I'm a bit stuck on how to do this, though. Could anyone help me out?