{"id":23530226,"url":"https://github.com/nocd5/md2html","last_synced_at":"2025-04-22T17:25:10.063Z","repository":{"id":43481888,"uuid":"55159379","full_name":"nocd5/md2html","owner":"nocd5","description":"Markdown to single HTML","archived":false,"fork":false,"pushed_at":"2022-10-20T09:29:28.000Z","size":21214,"stargazers_count":53,"open_issues_count":2,"forks_count":10,"subscribers_count":2,"default_branch":"master","last_synced_at":"2025-03-29T17:11:43.822Z","etag":null,"topics":["golang","markdown","md2html"],"latest_commit_sha":null,"homepage":null,"language":"Go","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"mit","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/nocd5.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":"LICENSE","code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null}},"created_at":"2016-03-31T15:01:29.000Z","updated_at":"2025-03-08T07:18:43.000Z","dependencies_parsed_at":"2023-01-20T03:19:22.760Z","dependency_job_id":null,"html_url":"https://github.com/nocd5/md2html","commit_stats":null,"previous_names":[],"tags_count":18,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/nocd5%2Fmd2html","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/nocd5%2Fmd2html/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/nocd5%2Fmd2html/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/nocd5%2Fmd2html/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/nocd5","download_url":"https://codeload.github.com/nocd5/md2html/tar.gz/refs/heads/master","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":250286089,"owners_count":21405362,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2022-07-04T15:15:14.044Z","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":["golang","markdown","md2html"],"created_at":"2024-12-25T21:16:20.890Z","updated_at":"2025-04-22T17:25:10.034Z","avatar_url":"https://github.com/nocd5.png","language":"Go","funding_links":[],"categories":[],"sub_categories":[],"readme":"# md2html\n\n[![Build status](https://github.com/nocd5/md2html/workflows/Build/badge.svg?branch=master)](https://github.com/nocd5/md2html/actions?query=workflow%3ABuild+branch%3Amaster)\n![Test status](https://github.com/nocd5/md2html/workflows/Test/badge.svg?branch=master)\n\nMarkdown to single HTML converter.\n\n## Feature\n\nThe **md2html** converts Markdown to a single file HTML.  \nAll scripts and css will be embeded in the file  \nand thus the converted file is viewable even offline.  \nAdditionally, the **md2html** has option to embed image to HTML by base64 encode  \nand hence the file is conveyable without any resources.\n\n## Sample\n\n[Github Pages](https://nocd5.github.io/md2html/index.html)\n\nThe html file is generated by following command\n\n```bash\n$ md2html example/*.md -e -t -m -s -f example/img/nocd5.png -c example/css/custom-css.css -o gh-pages/index.html\n```\n\n## Installation\n\n`go install github.com/nocd5/md2html/v2@latest`\n\n## Usage\n\n`md2html -i \u003cinput Markdown\u003e [-o \u003coutput HTML\u003e] [-e] [-t] [-m] [-s] [-f \u003cpath to icon\u003e]`\n\nif `-o` option was abbreviated, `input Markdown file name` + `.html` will be used as output HTML file name.\n\n### Embedding images\n\n`-e/--embed` option enables embedding images that are located local storage by Base64 encoding.\n\n### TOC\n\n`-t/--toc` option enables generating TOC.\n\n### Using MathJax\n\n`-m/--mathjax` option enables using MathJax.\n\n### Table row/col span\n\n`-s/--span` option enables using rowspan/colspan for table tag\n\n### Favicon\n\n`-f/--favicon \u003cpath/to/icon\u003e` option enables embedding icon for favicon\n\n### Add custom CSS\n\n`-c/--css \u003cpath/to/css\u003e` option enables additional CSS\n\n## Example\n\nPlease execute the following commands to make example files.\n\n```bash\n# make html files from each markdown files\n$ md2html -e example/*.md\n\n# make a concatinated single html file from markdown files\n$ md2html -e -t example/*.md -o example/concat.html\n```\n\n## Custom JS \u0026 CSS\n\n```bash\n$ go get -d github.com/nocd5/md2html\n$ cd ${GOPATH}/src/github.com/nocd5/md2html\n\n###########################################################\n# customize \"{$GOPATH}/src/github.com/nocd5/md2html/src/\" #\n###########################################################\n\n$ npm install \u0026\u0026 gulp\n$ assets.go.rb\n$ go install\n```\n\n## Use libraries\n\n#### Go\n\n- [yuin/goldmark](https://github.com/yuin/goldmark)\n  ([License](https://raw.githubusercontent.com/yuin/goldmark/master/LICENSE))\n- [yuin/goldmark-highlighting](https://github.com/yuin/goldmark-highlighting)\n  ([License](https://raw.githubusercontent.com/yuin/goldmark-highlighting/master/LICENSE))\n- [PuerkitoBio/goquery](https://github.com/PuerkitoBio/goquery)\n  ([License](https://raw.githubusercontent.com/PuerkitoBio/goquery/master/LICENSE))\n- [jessevdk/go-flags](https://github.com/jessevdk/go-flags)\n  ([License](https://raw.githubusercontent.com/jessevdk/go-flags/master/LICENSE))\n\n#### JS\n\n- [pkra/MathJax-single-file](https://github.com/pkra/MathJax-single-file)\n  ([License](https://raw.githubusercontent.com/pkra/MathJax-single-file/master/LICENSE))\n- [cferdinandi/smooth-scroll](https://github.com/cferdinandi/smooth-scroll)\n  ([License](https://raw.githubusercontent.com/cferdinandi/smooth-scroll/master/LICENSE.md))\n\n#### CSS\n- [sindresorhus/generate-github-markdown-css](https://github.com/sindresorhus/generate-github-markdown-css)\n  ([License](https://raw.githubusercontent.com/sindresorhus/generate-github-markdown-css/master/license))\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fnocd5%2Fmd2html","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fnocd5%2Fmd2html","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fnocd5%2Fmd2html/lists"}