use js to apply stylesheet
xxxxxxxxxx
function addFont(font, fontName){
const link = document.createElement("link")
link.href = font;
link.rel = "stylesheet"
document.body.insertBefore(link, target);
console.log(link)
document.body.style.fontFamily = fontName;
}
addFont("https://fonts.googleapis.com/css2?family=Roboto&display=swap", "'Roboto', sans-serif")
xxxxxxxxxx
Programming is like a "choose your
own adventure game" except every
path leads you to a StackOverflow
question from 2013 describing the
same bug, with no answer.
So, you're searching for the holy grail?
xxxxxxxxxx
https://stackoverflow.com/
Here it is. I hope you dont mind me drinking out of it first
Dont only copy the code, try to understand it!