2 comments

  • mlysk 3 hours ago

    Love it! Will keep this in mind for copy action for colibri https://news.ycombinator.com/item?id=47258337

  • cauethenorio 8 hours ago

    Slack is great in almost all aspects, but they dropped the ball on pasting formatted content.

    Over the years I've spent hours fixing the formatting of Markdown content I pasted into Slack: removing stray asterisks, rebuilding links, and re-indenting nested lists. Especially in the last months where half my messages come from ChatGPT or Claude.

    There are tools out there to help with this, but none of them can handle nested lists properly.

    Then I noticed something: when you copy text from Slack's compose bar and paste it back, nested lists survive. Something on the clipboard was preserving the formatting. So I dug in, reverse-engineered the clipboard format, and then did what everyone does in 2026: vibe-coded the rest with Claude.

    Slack's compose bar is a Quill editor. When you copy from it, it adds to the clipboard two MIME types: the standard text/plain and a custom `slack/texty` one containing Quill Delta JSON.

    Paste that back and everything comes through perfectly: bold, links, code blocks, and nested lists.

    So I built slackfmt to exploits this:

    1. Converts your Markdown (or HTML) to Quill Delta JSON

    2. Packs the Delta into a Chromium Pickle binary blob tagged as `slack/texty`

    3. Writes it to the system clipboard via a native Rust addon

    When you paste, Slack thinks you're pasting from Slack itself.

    Web: https://slackfmt.labs.caue.dev

    CLI: echo "*bold* and _italic_" | npx @slackfmt/cli@latest

    Repo: https://github.com/cauethenorio/slackfmt