Render only main Outline sections #1948
Unanswered
nicktahani
asked this question in
Q&A
Replies: 0 comments
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Uh oh!
There was an error while loading. Please reload this page.
Uh oh!
There was an error while loading. Please reload this page.
-
I didn't find this asked anywhere, but is there a prop that can be passed to the
Outlinecomponent to only render main sections? When inspectingOutline, I notice it rendersOutlineItemcomponents as children -- I'd like to be able to turn this off.It doesn't seem like
react-pdfsupports this, but I thought I may be missing something. I know pdf.js exposes agetOutline()method. Here's a rough workaround (open to suggestions on improving this) to illustrate what I mean.As you can see, I'm pretty much creating my own
Outlinecomponent. I was just wondering if there was a better way that didn't feel so hacky. Thanks!Beta Was this translation helpful? Give feedback.
All reactions