You can get a list of all loaded fonts through Array.from(document.fonts.keys())
This returns an array of FontFace objects.
How do you convert a FontFace object to @font-face css rule.
The main problem I'm facing is that there is no src property on FontFace Objects. And src property is required to make a @font-face rule.
@font-face {
font-family: myFirstFont;
src: url(sansation_light.woff);
}