Open fmmattioni opened 2 years ago
I'm facing the same issue, is there a way to workaround this?
Here is the solution that worked for me. Download Montserrat.ttf
file and place it in your project folder like my-project/fonts/Montserrat.ttf
. Now set your fonts directory in FONTCONFIG_PATH
environment variable as process.env.FONTCONFIG_PATH=/var/task/my-project/fonts
(/var/task
is the folder where lambda places your project). Deploy your function and it should work.
Hi,
I have been trying, without much success, to compile an HTML template into PDF in a AWS lambda function with the correct special characters.
I have included in the
head
of my HTML template the following:and in css I have this:
It renders all the fonts correctly, with the exception of this special character:
V̇
, which can also be written like this in HTML:V̇
.Looking at the google fonts website, it looks like this font can indeed render this character: https://fonts.google.com/specimen/Montserrat?query=montserrat&preview.text=V%CC%87&preview.text_type=custom
However, my PDF is rendered as squares. I was wondering if I should be installing another font in order for this to work?