{"id":16864349,"url":"https://github.com/nickserv/doc-validator","last_synced_at":"2025-09-09T04:40:23.228Z","repository":{"id":52611107,"uuid":"351997308","full_name":"nickserv/doc-validator","owner":"nickserv","description":"A library/tool for validating JavaScript code in Markdown documentation","archived":false,"fork":false,"pushed_at":"2023-03-05T23:18:14.000Z","size":299,"stargazers_count":5,"open_issues_count":15,"forks_count":2,"subscribers_count":3,"default_branch":"main","last_synced_at":"2025-09-06T04:46:44.638Z","etag":null,"topics":[],"latest_commit_sha":null,"homepage":"","language":"JavaScript","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":null,"status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/nickserv.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":"CONTRIBUTING.md","funding":null,"license":null,"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},"funding":{"github":"nickmccurdy"}},"created_at":"2021-03-27T06:13:36.000Z","updated_at":"2023-09-08T18:20:23.000Z","dependencies_parsed_at":"2024-08-02T11:59:18.124Z","dependency_job_id":"8997c1b3-0b01-43ce-ac39-e00e93f4f345","html_url":"https://github.com/nickserv/doc-validator","commit_stats":null,"previous_names":["nickserv/doc-validator"],"tags_count":6,"template":false,"template_full_name":null,"purl":"pkg:github/nickserv/doc-validator","repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/nickserv%2Fdoc-validator","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/nickserv%2Fdoc-validator/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/nickserv%2Fdoc-validator/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/nickserv%2Fdoc-validator/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/nickserv","download_url":"https://codeload.github.com/nickserv/doc-validator/tar.gz/refs/heads/main","sbom_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/nickserv%2Fdoc-validator/sbom","scorecard":null,"host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":274244220,"owners_count":25248157,"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","status":"online","status_checked_at":"2025-09-09T02:00:10.223Z","response_time":80,"last_error":null,"robots_txt_status":"success","robots_txt_updated_at":"2025-07-24T06:49:26.215Z","robots_txt_url":"https://github.com/robots.txt","online":true,"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":[],"created_at":"2024-10-13T14:41:46.412Z","updated_at":"2025-09-09T04:40:23.204Z","avatar_url":"https://github.com/nickserv.png","language":"JavaScript","funding_links":["https://github.com/sponsors/nickmccurdy"],"categories":[],"sub_categories":[],"readme":"# `doc-validator`\n\nA library/tool for validating JavaScript code in Markdown documentation\n\n## [Inspiration](https://twitter.com/bitandbang/status/1375534850506129418)\n\n## Status\n\nIn development. JavaScript code in Markdown documentation can be parsed via the API or CLI, but there is no support for running code yet (see [1.0.0 milestone](https://github.com/nickmccurdy/doc-validator/milestone/1)).\n\n## Usage\n\n### Library\n\nInstall `doc-validator` as a dependency. All commands take a Markdown source string and return an Array of any Errors reported. Errors are not thrown to make it easier to detect multiple errors from separate JavaScript code examples in the same file, so you will probably want to print or throw them.\n\n### Tool\n\nInstall `doc-validator` globally for any project, or as a local development dependency for CI and test scripts. Use with a filename like `doc-validator parse README.md` to parse existing Markdown files, or pass stdin with no path argument for advanced scripting.\n\n## API\n\n### `parse`\n\nParses JavaScript using Babel. Modern standardized syntax is supported, including ES modules (supported by Node).\n\n````js\nconst { parse } = require(\"doc-validator\")\n;(async () =\u003e {\n  await parse('```js\\nconsole.log(\"Hello, world!\")\\n```')\n})()\n````\n\n### Planned\n\n- `type`\n- `run`\n- `test`\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fnickserv%2Fdoc-validator","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fnickserv%2Fdoc-validator","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fnickserv%2Fdoc-validator/lists"}