{"id":13623309,"url":"https://github.com/aleen42/gitbook-treeview","last_synced_at":"2025-04-15T11:50:21.234Z","repository":{"id":57251186,"uuid":"65435087","full_name":"aleen42/gitbook-treeview","owner":"aleen42","description":":evergreen_tree: A gitbook plugin for generating tree view for ech page","archived":false,"fork":false,"pushed_at":"2023-01-18T09:30:00.000Z","size":648,"stargazers_count":39,"open_issues_count":1,"forks_count":14,"subscribers_count":2,"default_branch":"master","last_synced_at":"2025-03-28T19:44:45.719Z","etag":null,"topics":["gitbook","gitbook-plugin","page-treeview","treeview"],"latest_commit_sha":null,"homepage":"","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/aleen42.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":".github/FUNDING.yml","license":"LICENSE","code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null},"funding":{"patreon":"aleen42","custom":["http://paypal.me/aleen42","https://www.buymeacoffee.com/aleen42"]}},"created_at":"2016-08-11T03:22:27.000Z","updated_at":"2023-09-03T08:25:13.000Z","dependencies_parsed_at":"2023-02-10T14:15:49.235Z","dependency_job_id":null,"html_url":"https://github.com/aleen42/gitbook-treeview","commit_stats":null,"previous_names":[],"tags_count":45,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/aleen42%2Fgitbook-treeview","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/aleen42%2Fgitbook-treeview/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/aleen42%2Fgitbook-treeview/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/aleen42%2Fgitbook-treeview/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/aleen42","download_url":"https://codeload.github.com/aleen42/gitbook-treeview/tar.gz/refs/heads/master","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":248331962,"owners_count":21086008,"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":["gitbook","gitbook-plugin","page-treeview","treeview"],"created_at":"2024-08-01T21:01:30.231Z","updated_at":"2025-04-15T11:50:21.214Z","avatar_url":"https://github.com/aleen42.png","language":"JavaScript","readme":"## page-treeview\n\n![gitbook](https://cdn.rawgit.com/aleen42/badges/master/src/gitbook_1.svg) ![gitbook](https://cdn.rawgit.com/aleen42/badges/master/src/gitbook_2.svg) [![Pay](https://img.shields.io/badge/%24-free-%23a10000.svg)](#) [![GitHub issues](https://img.shields.io/github/issues/aleen42/gitbook-treeview.svg)](https://github.com/aleen42/gitbook-treeview/issues) [![GitHub license](https://img.shields.io/badge/license-MIT-blue.svg)](https://raw.githubusercontent.com/aleen42/gitbook-treeview/master/LICENSE) [![Gitter](https://badges.gitter.im/aleen42/gitbook-treeview.svg)](https://gitter.im/aleen42/gitbook-treeview?utm_source=badge\u0026utm_medium=badge\u0026utm_campaign=pr-badge)\n\n[![npm](https://img.shields.io/npm/v/gitbook-plugin-page-treeview.svg)](https://www.npmjs.com/package/gitbook-plugin-page-treeview) [![Build Status](https://travis-ci.org/aleen42/gitbook-treeview.svg?branch=master)](https://travis-ci.org/aleen42/gitbook-treeview) [![devDependency Status](https://david-dm.org/aleen42/gitbook-treeview/dev-status.svg)](https://david-dm.org/aleen42/gitbook-treeview#info=devDependencies) [![npm](https://img.shields.io/npm/dt/gitbook-plugin-page-treeview.svg)](https://www.npmjs.com/package/gitbook-plugin-page-treeview)\n\na gitbook-plugin for generating a \"Treeview\" for each page.\n\n![page-treeview](https://raw.githubusercontent.com/aleen42/gitbook-treeview/master/1.png)\n\n### Installation\n\nadd the following plugins to your `book.json` and run `gitbook install`\n\n```json\n{\n    \"plugins\": [\"page-treeview\"]\n}\n```\n\n### Usage\n\njust find plugin on gitbook and install it on your gitbook project.\n\nconfiguration option can be set as an obj like, and of course you can use a default value shown as followed:\n\n```json\n{\n\t\"plugins\": [\n\t\t\"page-treeview\"\n\t],\n\t\"pluginsConfig\": {\n\t\t\"page-treeview\": {\n\t\t\t\"copyright\": \"Copyright \u0026#169; aleen42\",\n\t\t\t\"minHeaderCount\": \"2\",\n\t\t\t\"minHeaderDeep\": \"2\"\n\t\t}\n\t}\n}\n```\n\n### What Treeview looks like in Markdown?\n\nTreeview will only generate treeviews for headers between level 1 and 6. Here I'll list some cases with different structure (each number means the level a head tag, like 1 for \u0026lt;h1\u0026gt;):\n\n##### 1-1-2-3-4-1\n\n- 1\n- 1\n\t- 2\n\t\t- 3\n\t\t\t- 4\n- 1\n\n##### 3-4-2-3-4-5-1-2-3\n\n- \u0026nbsp;\n\t- \u0026nbsp;\n\t\t- 3\n\t\t\t- 4\n\t- 2\n\t\t- 3\n\t\t\t- 4\n\t\t\t\t- 5\n- 1\n\t- 2\n\t\t- 3\n\n\u003ca\u003e\n\n\u003c/a\u003e\n\n##### 1-2-3-1-3-4-5-1-2\n\n- 1\n\t- 2\n\t\t- 3\n- 1\n\t- \u0026nbsp;\n\t\t- 3\n\t\t\t- 4\n\t\t\t\t- 5\n- 1\n\t- 2\n\n### Tests\n\n```bash\nnpm test\n```\n\n### Release History\n\n* ==================== **1.0.0 Initial release** ====================\n\t* 1.5.7 release version\n\t* 1.5.8 fix bugs\n\t* 1.5.9 fix bugs of chinese\n\t* 1.6.1 fix bugs of text indent in markdown style\n\t* 1.6.9 fix bugs\n\t* 1.8.0 fix bugs\n\t* 1.8.3 fix bugs\n* ==================== **2.0.0 Style release** ====================\n\t* 2.0.1 update style\n\t* 2.0.2 update style\n\t* 2.0.5 update style\n\t* 2.0.6 update style\n\t* 2.0.7 update readme\n\t* 2.1.3 fix bugs\n\t* 2.2.1 fix bugs\n\t* 2.2.2 fix bugs\n\t* 2.3.0 fix bugs\n\t* 2.3.4 fix bugs\n\t* 2.3.5 fix bugs\n\t* 2.3.7 fix bugs\n\t* 2.3.8 update readme\n\t* 2.4.0 update configuration\n\t* 2.4.1 restrict reading book\n\t* 2.4.3 fix bugs\n\t* 2.4.4 fix bugs\n\t* 2.4.5 update readme\n\t* 2.4.9 fix bugs\n\t* 2.5.0 update readme\n\t* 2.5.8 enhancement for issue [#2](https://github.com/aleen42/gitbook-treeview/issues/2)\n\t* 2.5.9 update default value\n\t* 2.6.1 fix bugs\n\t* 2.6.5 fix bugs\n\t* 2.6.7 fix bugs\n\t* 2.6.8 update readme\n\t* 2.6.9 update readme\n\t* 2.7.2 fix bugs\n\t* 2.7.3 update readme\n\t* 2.7.4 disable console\n    * 2.7.7 fix bugs\n    * 2.9.5 featuring collapsible lists\n    * 2.9.6 update readme\n\t* 2.9.7 fix bugs\n\t* 2.9.8 fix the bug of stripping list leader when removing markdown of titles\n* ==================== **3.0.0 Refactor release** ====================\n    * 3.0.1 fix the bug when calculating headers' level\n    * 3.0.2 support collapsed option (`false` by default) [#8](https://github.com/aleen42/gitbook-treeview/issues/8)\n    * 3.0.3 use [marked](https://github.com/markedjs/marked) to convert markdown into plain text\n    * 3.0.6 use gitbook-color to support light or dark theme\n\n### :fuelpump: How to contribute\n\nHave an idea? Found a bug? See [how to contribute](https://aleen42.gitbooks.io/personalwiki/content/contribution.html).\n\n### :scroll: License\n\n[MIT](https://aleen42.gitbooks.io/personalwiki/content/MIT.html) © aleen42\n\n*Note: if you like this project, feel free to buy me a swimming chance:*\n\n[![badges](https://badges.aleen42.com/src/paypal.svg)](http://paypal.me/aleen42) [![badges](https://badges.aleen42.com/src/patreon.svg)](https://www.patreon.com/aleen42) [![badges](https://badges.aleen42.com/src/buymeacoffee.svg)](https://www.buymeacoffee.com/aleen42)\n","funding_links":["https://patreon.com/aleen42","http://paypal.me/aleen42","https://www.buymeacoffee.com/aleen42","https://www.patreon.com/aleen42"],"categories":["JavaScript"],"sub_categories":[],"project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Faleen42%2Fgitbook-treeview","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Faleen42%2Fgitbook-treeview","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Faleen42%2Fgitbook-treeview/lists"}