JSFiddle - React, Tailwind, and code Playground
JavaScript
const comfortaa = new FontFace('Comfortaa', "url('https://fonts.googleapis.com/css?family=Comfortaa&display=swap')");
comfortaa.load().then(function(loaded_face) {
// loaded_face holds the loaded FontFace
console.log("sucesso")
}).catch(function(error) {
// error occurred
console.log(error)
});