Skip to content

Commit

Permalink
feat(src content-script): remove HTML tags from answers
Browse files Browse the repository at this point in the history
  • Loading branch information
cmnord committed Mar 7, 2023
1 parent fff5b51 commit 20ce7ad
Showing 1 changed file with 3 additions and 1 deletion.
4 changes: 3 additions & 1 deletion src/content-script.ts
Expand Up @@ -155,7 +155,9 @@ class FinalRoundParser {

const categoryDiv = roundDiv.querySelector(".category");
const mouseOverDiv = categoryDiv?.children[0];
this.answer = parseCorrectResponse(mouseOverDiv, "final jeopardy");
const answerHtml = parseCorrectResponse(mouseOverDiv, "final jeopardy");
// Remove HTML tags from the answer
this.answer = answerHtml.replace(/<[^>]*>/g, "");
}

jsonify() {
Expand Down

0 comments on commit 20ce7ad

Please sign in to comment.