{"id":19225964,"url":"https://github.com/gopherlabsltd/tictoc","last_synced_at":"2026-04-18T07:35:32.453Z","repository":{"id":57165985,"uuid":"184848546","full_name":"GopherLabsLtd/ticTOC","owner":"GopherLabsLtd","description":"A framework-agnostic automated table of contents component! ✨","archived":false,"fork":false,"pushed_at":"2019-05-11T01:54:46.000Z","size":266,"stargazers_count":1,"open_issues_count":5,"forks_count":0,"subscribers_count":2,"default_branch":"master","last_synced_at":"2024-04-23T20:05:58.793Z","etag":null,"topics":["javascript","toc","typescript"],"latest_commit_sha":null,"homepage":"https://tictoc.netlify.com/","language":"TypeScript","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/GopherLabsLtd.png","metadata":{"files":{"readme":"README.md","changelog":null,"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":"2019-05-04T03:39:39.000Z","updated_at":"2020-11-09T20:07:58.000Z","dependencies_parsed_at":"2022-08-30T15:21:24.049Z","dependency_job_id":null,"html_url":"https://github.com/GopherLabsLtd/ticTOC","commit_stats":null,"previous_names":[],"tags_count":0,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/GopherLabsLtd%2FticTOC","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/GopherLabsLtd%2FticTOC/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/GopherLabsLtd%2FticTOC/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/GopherLabsLtd%2FticTOC/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/GopherLabsLtd","download_url":"https://codeload.github.com/GopherLabsLtd/ticTOC/tar.gz/refs/heads/master","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":240298846,"owners_count":19779346,"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":["javascript","toc","typescript"],"created_at":"2024-11-09T15:16:56.222Z","updated_at":"2026-04-18T07:35:32.410Z","avatar_url":"https://github.com/GopherLabsLtd.png","language":"TypeScript","funding_links":[],"categories":[],"sub_categories":[],"readme":"# TicTOC [![NPM package](https://img.shields.io/npm/v/@theiliad/tictoc.svg)](https://www.npmjs.com/package/@theiliad/tictoc) ![Bundle Size](https://img.shields.io/badge/bundle%20size-\u003c3kb-brightgreen.svg) [![License](https://img.shields.io/npm/l/@theiliad/tictoc.svg)](https://github.com/GopherLabsLtd/ticTOC/blob/master/LICENSE.md)\n\nA framework-agnostic automated table of contents component! Super simple to use, just provide a content container and another container where the TOC would be mounted, and Voila!\n\n## Demo\nCheckout the demo page [here](https://tictoc.netlify.com/).\n\n\u003cimg src=\"./docs/preview.png\" width=\"250\" /\u003e\n\n## Getting started\n\n### Installation:\n```bash\nnpm i --save @theiliad/tictoc\n```\n\n## Usage\nYou need to create a `div` (or any other DOM element) inside of which you'd like the TOC to be mounted (in this case we're using `\u003cdiv id=\"toc\"\u003e`, as well as another element that includes your content (in this case `\u003cdiv id=\"article-content\"\u003e`.\n\n**import/require:**\n```js\nimport TicTOC from \"@theiliad/tictoc/index\";\nimport \"@theiliad/tictoc/styles.css\";\n\nnew TicTOC({\n  contentContainer: document.getElementById(\"article-content\"),\n  mountTo: document.getElementById(\"toc\")\n});\n```\n\n**In-browser CDN usage:**\n```html\n\u003clink rel=\"stylesheet\" href=\"https://unpkg.com/@theiliad/tictoc@{VERSION_NUMBER_HERE}/styles.css\"\u003e\n\u003cscript src=\"https://unpkg.com/@theiliad/tictoc@{VERSION_NUMBER_HERE}/index.browser.js\"\u003e\u003c/script\u003e\n\u003cscript\u003e\n  new TicTOC.TicTOC({\n    contentContainer: document.getElementById(\"article-content\"),\n    mountTo: document.getElementById(\"toc\")\n  });\n\u003c/script\u003e\n```\n\n## API Reference\nThe project is built using *Typescript*, with minimal dependency usage.\n\nTypedoc generated API references can be found [here](https://tictoc.netlify.com/api-reference).\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fgopherlabsltd%2Ftictoc","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fgopherlabsltd%2Ftictoc","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fgopherlabsltd%2Ftictoc/lists"}