It would be useful to be able to specify custom TextSpans (perhaps either as contents of a Paragraph object, or in a new obj_type). This would allow for mixing and matching of fonts/styles in inline text and make wasm-pdf much more flexible for generating text-based documents.
In our particular use case, we would like to be able to generate a PDF from user-supplied rich text, but wasm-pdf only currently supports bold and hyperlink styles inline. Converting from HTML to a JSON object is straightforward enough in modern browsers
It would be useful to be able to specify custom TextSpans (perhaps either as
contents
of a Paragraph object, or in a new obj_type). This would allow for mixing and matching of fonts/styles in inline text and make wasm-pdf much more flexible for generating text-based documents.In our particular use case, we would like to be able to generate a PDF from user-supplied rich text, but wasm-pdf only currently supports bold and hyperlink styles inline. Converting from HTML to a JSON object is straightforward enough in modern browsers