If you are fun of Simpsons you can get everyday a new episode 😃
// Name: simpsons// Description: Show next episode of Simpsons// Author: Daniel Ostapenko// Twitter: @denielerimport '@johnlindquist/kit'const simpsonsDB = await db('simpsons', {season: 7,episode: 0,episodesData: []})if (!simpsonsDB.episodesData.length) {const wtf = await npm('wtf_wikipedia')const doc = await wtf.fetch('List of The Simpsons episodes')let episodes = doc.section('Episodes')let episodesText = episodes.text()const episodesRegexp = /episodes(\d*) = (\d*)/glet episodesData = episodesText.match(episodesRegexp)episodesData = episodesData.map(x => {const [_season, _numberOfEpisodes] = x // episodes1 = 13.replace('episodes', '') // '1 = 13'.split(' = ') // ['1', '13']return {season: parseInt(_season),numberOfEpisodes: parseInt(_numberOfEpisodes)}})simpsonsDB.episodesData = episodesDataawait simpsonsDB.write()}let season = simpsonsDB.seasonlet episode = simpsonsDB.episodeconst seasonEpisodes = simpsonsDB.episodesData.find(x => x.season === season)if (episode + 1 > seasonEpisodes.numberOfEpisodes) {const seasonNumbers = simpsonsDB.episodesData.map(x => x.season)const maxSeason = seasonNumbers[seasonNumbers.length - 1]if (season + 1 > maxSeason) {season = 7episode = 1} else {season = season + 1episode = 1}} else {episode = episode + 1}simpsonsDB.season = seasonsimpsonsDB.episode = episodeawait simpsonsDB.write()const episodeUrl = `https://www.wcofun.com/the-simpsons-season-${season}-episode-${episode}`browse(episodeUrl)