It is possible to set as Section child a TextRun without using a Paragraph #1642
sentientmachin3
started this conversation in
General
Replies: 1 comment
-
Not possible sorry, Every TextRun needs to be in a paragraph Unfortunately, thats simply how Word works |
Beta Was this translation helpful? Give feedback.
0 replies
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
-
I don't think this is an issue, but I find it useful to highlight it in case someone else encounters this behaviour. Accidentally I passed as Section child a TextRun instead of a paragraph:
The compiler did not complain about it, so I tried it and the document was just a blank page. According to the documentation and the type definition we are supposed to pass
(Paragraph | Table | TableOfContents)[]
aschildren
.Passing a
Paragraph
did solve the "issue".Versions: TS 4.7.2, library version 7.4.1
I don't know why the compiler does not complain, any explanations?
Beta Was this translation helpful? Give feedback.
All reactions