Skip to content
Discussion options

You must be logged in to vote

The structure pandoc produces is a faithful rendition of what is in the EPUB.

However, you can use a Lua filter to make it work the way you want. See the docs on Lua filters.

Essentially you want your filter to change Link elements that look like

      Link
        ( "" , [] , [] )
        [ Span
            ( "06_Contents.xhtml_int1" , [] , [] )
            [ Span
                ( "06_Contents.xhtml_kobo.2.1"
                , [ "koboSpan" ]
                , [ ( "xmlns" , "http://www.w3.org/1999/xhtml" ) ]
                )
                [ Str "INTRODUCTION" ]
            ]
        ]
        ( "#07_INTRODUCTION.xhtml#int1a" , "" )

into

Link
        ( "" , [ "wikilink" ] , [] )
      …

Replies: 1 comment 4 replies

Comment options

You must be logged in to vote
4 replies
@jm355
Comment options

@jm355
Comment options

@jgm
Comment options

jgm Mar 31, 2025
Maintainer

Answer selected by jm355
@jm355
Comment options

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Category
Q&A
Labels
None yet
2 participants