0

When I try to put an json as content it does render as a whole string. So I see the json syntax in the pdf, instead of the formated. What did I miss?

var docDefinition = {
content: jsonObj,
styles: {
 header: {
   fontSize: 22,
   bold: true
 },
 anotherStyle: {
   italic: true,
   alignment: 'right'
 }
}
};
user1308302
  • 193
  • 9

1 Answers1

0

Ok. Turns out, that the array had pushed strings instead of objects. So code example is working.

user1308302
  • 193
  • 9