{"repo":"kepano/defuddle","free":true,"listed":false,"github":"https://github.com/kepano/defuddle","clone":"git clone https://github.com/kepano/defuddle.git","description":"Get the main content of any page as Markdown.","language":"TypeScript","stars":9023,"topics":["defuddle","cli","html","markdown","md","readability","obsidian"],"license":"MIT","category":"cli-tools","readme_excerpt":"de·​fud·dle /diˈfʌdl/ transitive verb to remove unnecessary elements from a web page, and make it easily readable. Beware! Defuddle is very much a work in progress! Defuddle extracts the main content from web pages. It cleans up web pages by removing clutter like comments, sidebars, headers, footers, and other non-essential elements, leaving only the primary content. Overview Defuddle takes a URL or HTML, finds the main content, and returns cleaned HTML or Markdown. Defuddle was created for the browser extension Obsidian Web Clipper, but it is designed to run in any environment. Defuddle can be used as a replacement for Mozilla Readability with a few differences: - More forgiving, removes fewer uncertain elements. - Provides a consistent output for footnotes, math, code blocks, etc. - Uses a page's mobile styles to guess at unnecessary elements. - Extracts more metadata from the page, including schema.org data. Usage Browser Node.js defuddle/node accepts a DOM Document from any implementation (JSDOM, linkedom, happy-dom, etc.). Or with JSDOM: Note: for defuddle/node to import properly, the module format in your package.json has to be set to { \"type\": \"module\" } CLI Defuddle includes a command-line interface for parsing web pages directly from the terminal. You can run it with npx or install it globally. The CLI accepts a file path, a URL, or HTML piped over stdin. CLI Options Option Alias Description -------- ------- ------------- --output -o Write output to a file instead of","default_branch":null,"files":null,"tree":[],"storefront":"/r/kepano","claimed":false,"request_supported":{"post":"https://gitbuyer.com/r/kepano/defuddle/request-supported","requests":0},"note":"indexed from public GitHub; nothing is for sale on this page. Clone it from GitHub. Paid listings live at /search."}