{"id":26685334,"url":"https://github.com/stackhtml/posthtmlify","last_synced_at":"2025-04-12T15:45:40.688Z","repository":{"id":57328838,"uuid":"104336531","full_name":"stackhtml/posthtmlify","owner":"stackhtml","description":"posthtml transform for documentify","archived":false,"fork":false,"pushed_at":"2019-08-27T12:25:44.000Z","size":56,"stargazers_count":7,"open_issues_count":1,"forks_count":4,"subscribers_count":1,"default_branch":"master","last_synced_at":"2025-03-26T10:15:13.301Z","etag":null,"topics":["documentify"],"latest_commit_sha":null,"homepage":null,"language":"JavaScript","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/stackhtml.png","metadata":{"files":{"readme":"readme.md","changelog":"CHANGELOG.md","contributing":null,"funding":null,"license":"LICENSE.md","code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null}},"created_at":"2017-09-21T10:53:33.000Z","updated_at":"2020-03-16T19:13:01.000Z","dependencies_parsed_at":"2022-09-13T23:12:01.231Z","dependency_job_id":null,"html_url":"https://github.com/stackhtml/posthtmlify","commit_stats":null,"previous_names":[],"tags_count":2,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/stackhtml%2Fposthtmlify","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/stackhtml%2Fposthtmlify/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/stackhtml%2Fposthtmlify/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/stackhtml%2Fposthtmlify/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/stackhtml","download_url":"https://codeload.github.com/stackhtml/posthtmlify/tar.gz/refs/heads/master","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":248591087,"owners_count":21129953,"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":["documentify"],"created_at":"2025-03-26T10:15:16.772Z","updated_at":"2025-04-12T15:45:40.666Z","avatar_url":"https://github.com/stackhtml.png","language":"JavaScript","funding_links":[],"categories":[],"sub_categories":[],"readme":"# posthtmlify\n\n[posthtml][] transform for [documentify][].\n\n[![npm][npm-image]][npm-url]\n[![travis][travis-image]][travis-url]\n[![standard][standard-image]][standard-url]\n\n[npm-image]: https://img.shields.io/npm/v/posthtmlify.svg?style=flat-square\n[npm-url]: https://www.npmjs.com/package/posthtmlify\n[travis-image]: https://img.shields.io/travis/stackhtml/posthtmlify.svg?style=flat-square\n[travis-url]: https://travis-ci.org/stackhtml/posthtmlify\n[standard-image]: https://img.shields.io/badge/code%20style-standard-brightgreen.svg?style=flat-square\n[standard-url]: http://npm.im/standard\n\n## Install\n\n```bash\nnpm install posthtmlify\n```\n\n## Usage\n\n### `package.json`\n\n```json\n{\n  \"documentify\": {\n    \"transform\": [\n      [\"posthtmlify\", {\n        \"use\": [\n          \"posthtml-custom-elements\"\n        ]\n      }]\n    ]\n  }\n}\n```\n\n### Node API\n\n```js\nvar documentify = require('documentify')\nvar posthtmlify = require('posthtmlify')\n\nvar d = documentify('./index.html').transform(posthtmlify, {\n  use: ['posthtml-custom-elements']\n})\n```\n\n### `documentify` cli:\n\n```bash\ndocumentify input.html -t posthtmlify \u003e output.html\n```\n\nWith options:\n\n```bash\ndocumentify input.html -t [ posthtmlify --use posthtml-custom-elements ] \u003e output.html\n```\n\nPassing options to posthtml plugins:\n\n```bash\ndocumentify input.html -t [ posthtmlify --use [ posthtml-include --root \"${PWD}\" ] ] \u003e output.html\n```\n\n## Options\n\n### `use: []`\n\nList of posthtml plugins to use.\nItems can be plugin names or factory functions, or arrays containing a plugin name or factory function and an options object.\n\n```js\nd.transform(posthtmlify, {\n  use: [\n    'posthtml-custom-elements',\n    ['posthtml-custom-elements', { option: 'value' }],\n    [require('posthtml-custom-elements'), {}]\n  ]\n})\n```\n\n### `parser: 'posthtml-parser'`\n\nHTML parser module to use.\nCan be a string module name or a parse function.\n\n```js\nd.transform(posthtmlify, {\n  parser: 'posthtml-pug'\n})\n```\n\n### `render: 'posthtml-render'`\n\nRender module to use.\nCan be a string module name or a parse function.\n\n```js\nd.transform(posthtmlify, {\n  render: 'posthtml-jsx'\n})\n```\n\n## License\n\n[MIT](LICENSE.md)\n\n[posthtml]: https://github.com/posthtml/posthtml\n[documentify]: https://github.com/stackhtml/documentify\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fstackhtml%2Fposthtmlify","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fstackhtml%2Fposthtmlify","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fstackhtml%2Fposthtmlify/lists"}