Here the Uthmanic font doesn’t get applied to the paragraph even though the link does work when tested in https://editor.p5js.org/
const htmlContent = "
<head>
<meta charset="UTF-8">
<meta name="viewport" content="width=device-width, initial-scale=1.0">
<title>p5.js Sketch</title>
<style>
@font-face {
font-family: 'Uthmanic';
src: url('https://cdn.jsdelivr.net/npm/kfgqpc-uthmanic-script-hafs-regular/arabic.otf') format('opentype');
}
body {
background-color: #000000;
margin: 0;
padding: 0;
color: #ffffff;
}
canvas {
display: block;
margin: auto;
border: 0px solid black;
}
</style>
</head>
<body>
<p> ﷽</p>
</body>"
I am confused as the exact same code works in the editor but doesn’t work here.
Thanks in advance for your help.