PDF Generation - state of the art?

I’ve found the tool Tiddly2PDF (discusssion) and was wondering if that was the current state of the art, or if folks know of other similar tools available.

This is a nice-to-have feature; it’s not critical to my plans. But what I would like to do is for each of my core tiddlers, offer a link to download it as a PDF. These are fairly complex tiddlers with recursive dynamic transclusions. The users will know nothing of TW; it will be just another website. The work-in-progress project is one I’ve shared in other threads: RHAM Policy Manual — Version 0.6.2 (Last updated January 20, 2026). Each of the Policy tiddlers, found in the second level of the TOC, would get this button.

I could run some batch script to generate all of these using a PDF print driver, but eventually there will be 150 or so of them, and unless I got very sophisticated about the process, I would have to regenerate all of them on every publish: doable, but annoying.

I’m perfectly happy writing print-specific CSS that would apply only here.

Any suggestions?

Tiddly2PDF is not printing all content of a tiddler.

WYSIWYG is not working - text and colors etc. are predefined.

1 Like

Personally, I use @Mohammad’s Printify plugin along with the browser’s integrated “export to PDF” functionality. It works quite well.

I do that myself regularly; it’s a fine technique. However for my intended audience, I would not want to ask them to do this. As mentioned, I could automate this somehow and run it during a build for every important document. But that has two problems. First, there are real possibilities of things getting out of sync. Second, this is a minor feature that I think few users will take advantage of. So I would much rather a dynamic solution. That would also allow me to use it on smaller sub-sections of a main document.

I didn’t mention in the OP, but the biggest objection to Tiddly2PDF is that the underlying PDFMake engine uses a proprietary formatting language. I would much rather use normal CSS for this.

You could always just use some custom CSS with formatting to dynamically alter the print style, then the user just has to use the “print” icon and select “print to PDF” instead of a their physical printer.

This is what I do and it works for what I need.

I’m also curious if TIddly2PDF out of the box respects any specified @media print styles and layers it’s definitions ‘on-top’ or if it does its own thing regardless.

@media print {
    /* =======================================================
       1. HIDE ALL NAVIGATION AND INTERFACE ELEMENTS
       (Ensures only content is printed)
       ======================================================= */
    
    /* Hide the entire custom top bar */
    .nc-topbar {
        display: none !important;
    }

    /* Hide the entire custom bottom bar */
    .nc-bottombar {
        display: none !important;
    }

    /* The main TiddlyWiki Sidebar and its header */
    .tc-sidebar-scrollable,
    .tc-sidebar-header {
        display: none !important;
    }
    
    /* HIDE THE TIDDLER TITLE BAR (including title and controls) */
    .tc-titlebar {
        display: none !important;
    }

    /* The main 'ViewToolbar' buttons (e.g., Edit, Delete, Tag, permalink) */
    .tc-tiddler-controls,
    .tc-toolbar-group,
    .tc-toolbar-item {
        display: none !important;
    }

    /* HIDE THE TIDDLER FOOTER (e.g., backlinks, filter results) */
    .footer {
        display: none !important;
    }

    /* TiddlyWiki's core style for the Edit Template buttons/footer */
    .tc-editor-footer {
        display: none !important;
    }

    /* The Control Panel button (top right) */
    .tc-more-toolbar-wrapper {
        display: none !important;
    }

    /* If you have a custom Tiddler that shows the edit state */
    .tc-edit-text-wrapper {
        display: none !important;
    }
    
    /* Hide the 'Add New Node' button/control from Streams plugin */
    .stream-node-control-addnew {
        display: none !important;
    }

    /* Hide the Tiddler Subtitle (Date/Time info) */
    .tc-subtitle {
        display: none !important;
    }

    /* Hide the Tiddler Tags wrapper */
    .tc-tags-wrapper {
        display: none !important;
    }

    /* =======================================================
       2. OPTIMIZE CONTENT DISPLAY
       (Ensures text takes up full page width)
       ======================================================= */

    /* Ensure the main content takes up the full width */
    .tc-tiddler-frame {
        width: 100% !important;
        margin-left: 0 !important;
        padding: 0 !important;
        /* Set page break to keep tiddlers from splitting awkwardly */
        page-break-inside: avoid;
    }
    
    /* Ensure the Story River expands to full width */
    .tc-story-river {
        width: 100% !important;
    }

    /* =======================================================
       3. GENERAL TIDDLER FRAME MODIFICATIONS
       (Removes borders and stream indentation lines)
       ======================================================= */
    
    /* Remove the top border from ALL Tiddler frames being printed */
    .tc-tiddler-frame {
        border-top: none !important; 
    }
    
    /* Remove the left indentation border from ALL stream children */
    .stream-row-children {
        border-left: none !important;
    }

    /* =======================================================
       4. TYPOGRAPHY & COLORS
       (Overrides dark mode text for printing)
       ======================================================= */

    /* Force body text to pure black for better print contrast */
    body.tc-body {
        color: #000000 !important;
    }
}

While I haven’t really played with Tiddly2PDF yet, the documentation for PDFMake seems to make it pretty clear that it only respects its own styling language.

For these sorts of wikis, I tend to develop useful print stylesheets, although I haven’t gotten to that point yet on the current project, but you can see the stylesheet I used on http://scott.sauyet.com/Tiddlywiki/WIP/Charter/v9/. I’m pretty happy with that, although I still don’t have an answer to one outstanding question.

The trouble with this technique is that this wiki isn’t for me – or not primarily for me. I expect all sorts of users, from high school students to their parents, teachers, and especially administrators, but also School Board members, and the wider community. I really would like them to be able to simply click a link and have their browser’s file download UI appear.

Again, though, this is not on the critical path for my application. I was just hoping there were other tools I could compare with one another to see which best met my needs.

1 Like