JS Reports doesn't show the Chinese language properly
-
All the fixed labels of reports mentioned in language files are being shown like this.
-
No failing request or error from Chrome is mentioned in the profile tab.
-
Could you share a minimal demo with HTML? How do you install/link the font awesome?
-
I'm using this for CSS:
@font-face {
font-family: 'fa-solid-900';
src: url('{{{asset "/assets/fa-solid-900.woff2" "dataURI"}}}')
format('woff2');
}
.fa {
font-family: 'fa-solid-900';
font-style: normal;
}Below is the example for HTML:
<div class="flex col">
{{#with data}}
<div class="flex row f-wrap w-full">
<div class="flex col b-1-4">
<div class="bold">{{@root.$localizedResource.orderNo}}</div>
<div>{{orderNo}}</div>
</div>
<div class="flex col b-1-4">
<div class="bold">{{@root.$localizedResource.itemNo}}</div>
<div>{{partNo}}</div>
</div>
<div class="flex col b-1-4">
<div class="bold">{{@root.$localizedResource.itemRev}}</div>
<div>{{partChg}}</div>
</div>
{{#if iconName}}
<div class="min-width">
<i class="fs-30 c-666 {{iconName}}"></i>
</div>
<div class="flex col b-1-4">
<div class="bold">{{@root.$localizedResource.location}}</div>
<div>{{location}}</div>
</div>
</div>
</div>In this iconName is coming like 'fa fa-tv'
-
Here is the playground link
https://playground.jsreport.net/w/anon/yRdYw7Sz
-
Seems you are missing proper charset in your HTML head
https://playground.jsreport.net/w/anon/nfINLojb
-
It worked.
Thanks
-
Hi @admin,
After production deployment it's printing like thisIts working fine in my local machine.
Is this possible any font issue on my production server?
Can you please help?
-
You can try to install server fonts like here
https://github.com/jsreport/jsreport/blob/master/packages/worker/Dockerfile#L21
-
I have not installed any other font on my local machine. But it's working locally.