{"id":25300135,"url":"https://github.com/deftio/docbat","last_synced_at":"2026-01-20T05:02:05.295Z","repository":{"id":43755563,"uuid":"226400147","full_name":"deftio/docbat","owner":"deftio","description":"docbat is a utility for converting markdown and some other text formats to \"nice\" HTML with minimal fuss.  Its defaults can be easily overridden at commandline or with simple JSON constructs. ","archived":false,"fork":false,"pushed_at":"2025-09-24T19:47:46.000Z","size":4522,"stargazers_count":0,"open_issues_count":1,"forks_count":0,"subscribers_count":1,"default_branch":"master","last_synced_at":"2025-10-26T13:04:34.270Z","etag":null,"topics":["docuemntation-tool","html-generator","markdown-converter","markdown-to-html","markdown-to-html-cli","markdown-to-html-converter"],"latest_commit_sha":null,"homepage":"","language":"HTML","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"other","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/deftio.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":"LICENSE.txt","code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null,"governance":null,"roadmap":null,"authors":null,"dei":null,"publiccode":null,"codemeta":null}},"created_at":"2019-12-06T19:59:52.000Z","updated_at":"2024-09-01T16:05:02.000Z","dependencies_parsed_at":"2024-05-29T06:34:09.523Z","dependency_job_id":"357767fd-5f71-4cc3-9568-760a0984d076","html_url":"https://github.com/deftio/docbat","commit_stats":null,"previous_names":[],"tags_count":0,"template":false,"template_full_name":null,"purl":"pkg:github/deftio/docbat","repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/deftio%2Fdocbat","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/deftio%2Fdocbat/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/deftio%2Fdocbat/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/deftio%2Fdocbat/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/deftio","download_url":"https://codeload.github.com/deftio/docbat/tar.gz/refs/heads/master","sbom_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/deftio%2Fdocbat/sbom","scorecard":null,"host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":286080680,"owners_count":28596087,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2026-01-20T02:08:49.799Z","status":"ssl_error","status_checked_at":"2026-01-20T02:08:44.148Z","response_time":117,"last_error":"SSL_read: unexpected eof while reading","robots_txt_status":"success","robots_txt_updated_at":"2025-07-24T06:49:26.215Z","robots_txt_url":"https://github.com/robots.txt","online":false,"can_crawl_api":true,"host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":["docuemntation-tool","html-generator","markdown-converter","markdown-to-html","markdown-to-html-cli","markdown-to-html-converter"],"created_at":"2025-02-13T05:38:31.463Z","updated_at":"2026-01-20T05:02:05.276Z","avatar_url":"https://github.com/deftio.png","language":"HTML","funding_links":[],"categories":[],"sub_categories":[],"readme":"[![License](https://img.shields.io/badge/License-BSD%202--Clause-blue.svg)](https://opensource.org/licenses/BSD-2-Clause)\n\n[![NPM version](https://img.shields.io/npm/v/docbat.svg?style=flat-square)](https://www.npmjs.com/package/docbat)\n\n[![docbat](./icon/docbat-logo-small.png)](http://www.deftio.com/docbat)\n\nDocbat is a simple javascript utility which takes coverts several file types to html pages.  This is useful for build scripts where you want to able to just browse a directory and have see the same content as a README.md but don't have a markdown viewer installed (say as a browser extension).\n\nDocbat provides methods to add formatting to the HTML page such as custom CSS or other constructs after the markdown conversion so that the HTML isn't just raw.  Docbat's default options provide simple margins and padding for reasonable view across desktop and mobile device contexts.\n\n## Simple Usage:\n```bash\nnpx docbat -i inputfile.md -o outputfile.html \n```\nif the -l parameter is included all libraries will be embedded in the page as a single stand alone file with support for code syntax higlighting.\n\n```bash\nnpx docbat -i inputfile.md -o outputfile.html -l\n```\n\nSupported input file types:\n* Markdown\n* raw text\n* tab delimited text (also see examples for adding titles)\n* images (no processing is performed on the images)\n\nSupported output:\n* HTML page (with default headers / titles which are overridable)\n* HTML raw (just HTML which can then be chained / piped together)\n* HTML-JSON - as a JSON construct (this leverages the bitwrench.js library, see that library for more details on npm or github)\n* proper formatting, including syntax highlighting for code blocks (via higlight.js)\n\nFuture: \nDocbat exposes the following file distribution libraries:\n* docbat.js     - ES5 / browser library for doing all operations.  \n* docbat.mjs    - ES6 module (uses export/import otherwise same as docbat.js)\n* docbat-cli.js - commandline program for scriptting operations\n\n\n## Usage at Commandline\n\nsimple usage to convert markdown to html\n\n```bash \n./docbat-cli.js -i myfile.md -o myoutput.html\n\ntype docbat --help for more commandline options\n```\n\n\nsimple usage to convert markdown to pdf\n\n```bash \n./docbat-cli.js -i myfile.md -o myoutput.pdf -p true\n\n```\n\n### Code Syntax Support\n\nCode syntax highlighting is supported.  Here is a Javascript example:\n\n```javascript\nlet addTwoNumbers = function(a,b) { return a+ b}\n\nconst myObject = {\n   \"one\": \"this is it,\n   2: [1,2,3,4,5],\n   3: { \"an embedded object\": \"I am a js object!\", 8 : \"eight\"}\n}\n\n```\n\nand here is python\n\n```python\n\"\"\"\nSimple python code example\n\"\"\"\n#import myLibrary\ndef addTwoNumbers(a,b)\n  return a+b\n\n```\n\n\n## Usage as a library\n\n\n## Dependencies (only important if building from source)\ndocbat uses the nodejs javscript runtime along with some packages which are available via the npmjs javascript packaging service.\n\nTechnologies:\n* nodejs javascript runtime -  [nodejs](https://nodejs.org/en/)  \n* npm - package manager javascript packages - [npm](https://docs.npmjs.com/cli/install)\n\nKey Packages:\n* showdown.js for markdown parsing - [showdown.js](https://www.npmjs.com/package/showdown)\n* bitwrench.js for page formatting duties - [bitwrench](https://www.npmjs.com/package/bitwrench)\n* command-line-args for argument processing - [command-line-args.js](https://www.npmjs.com/package/command-line-args)\n  \nFor buildings from Source:\n* webpack and webpackcli\n* del-cli\n\nFor Testing:\n* \n\n   \n\n## Source code home  \nall source is at github:  \n[docbat  on github](http://github.com/deftio/docbat )  \n\n\n## Linting \ndocbat  uses eslint for static code checking and analysis.\n\n```bash\nnpm install eslint --save-dev\n\n./node_modules/.bin/eslint --init\n\n```\nNow run the lint test like this:\n```bash\n./node_modules/.bin/eslint docbat.js   \n```\n\n## Release History  \n* 0.91 Initial release  \n* 0.94 added pdf output support\n  \n## License  \ndocbat  is released under the OSI Approved FreeBSD 2-clause license  \n\n\n\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fdeftio%2Fdocbat","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fdeftio%2Fdocbat","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fdeftio%2Fdocbat/lists"}