loadData
didn't work for me either, so I used file:///android_asset
in the src path.
It worked with loadDataWithBaseURL
!
For this example I changed the CSS to:
@font-face {
font-family: 'feast';
src: url('fonts/feasfbrg.ttf');
}
body {font-family: 'feast';}
Then use the assets path as the base url:
loadDataWithBaseURL("file:///android_asset/",myhtml,"text/html","utf-8",null);
与恶龙缠斗过久,自身亦成为恶龙;凝视深渊过久,深渊将回以凝视…