{"id":21761768,"url":"https://github.com/ionited/trail","last_synced_at":"2025-04-13T13:24:41.633Z","repository":{"id":57119140,"uuid":"412265939","full_name":"ionited/trail","owner":"ionited","description":"Guide your user, step by step","archived":false,"fork":false,"pushed_at":"2024-02-20T22:43:56.000Z","size":108,"stargazers_count":21,"open_issues_count":0,"forks_count":1,"subscribers_count":0,"default_branch":"main","last_synced_at":"2025-03-27T04:22:52.828Z","etag":null,"topics":["frontend","guide","step","tour","trail","ui","user","ux"],"latest_commit_sha":null,"homepage":"","language":"TypeScript","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/ionited.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":".github/FUNDING.yml","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},"funding":{"github":"gabrielcursino","patreon":null,"open_collective":null,"ko_fi":null,"tidelift":null,"community_bridge":null,"liberapay":null,"issuehunt":null,"otechie":null,"lfx_crowdfunding":null,"polar":null,"custom":null}},"created_at":"2021-09-30T23:58:18.000Z","updated_at":"2025-03-19T12:48:55.000Z","dependencies_parsed_at":"2022-08-22T23:31:22.553Z","dependency_job_id":"699ebbf9-7d60-4ec8-92c7-dc06fb680f3f","html_url":"https://github.com/ionited/trail","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/ionited%2Ftrail","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/ionited%2Ftrail/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/ionited%2Ftrail/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/ionited%2Ftrail/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/ionited","download_url":"https://codeload.github.com/ionited/trail/tar.gz/refs/heads/main","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":248719031,"owners_count":21150678,"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":["frontend","guide","step","tour","trail","ui","user","ux"],"created_at":"2024-11-26T12:09:43.186Z","updated_at":"2025-04-13T13:24:41.601Z","avatar_url":"https://github.com/ionited.png","language":"TypeScript","funding_links":["https://github.com/sponsors/gabrielcursino"],"categories":[],"sub_categories":[],"readme":"# Trail\n\n\u003cp align=\"center\"\u003e\n  \u003cimg src=\"docs/imgs/logo.png\" alt=\"Trail logo\" title=\"Trail logo\" width=\"256\"\u003e\n\u003c/p\u003e\n\n\u003e Guide your user, step by step\n\nA simple and lightweight tour library \n\n## Quick start\n\nChoose your favorite option below:\n\n### Install with NPM\n\n```\nnpm i @ionited/trail\n```\n\n### Get from UNPKG\n\n[https://unpkg.com/@ionited/trail@latest/dist/trail.js](https://unpkg.com/@ionited/trail@latest/dist/trail.js)\n\n---\n\n## Usage\n\nTo basic usage you can simply call:\n\n```js\nvar trail = Trail([{\n  id: 1,\n  content: 'First step',\n  attachedEl: document.getElementById('one')\n}, {\n  id: 2,\n  content: 'Step two, without attachedEl'\n}, {\n  id: 3,\n  content: 'Step 3',\n  attachedEl: document.getElementById('two'),\n  interactive: false\n}, {\n  id: 4,\n  content: 'Step 4, end of the line!',\n  attachedEl: document.getElementById('three')\n}]);\n```\n\n### Options\n\n```ts\nTrail(steps?: Step[]): TrailCore\n\nexport interface Step {\n  id: any;\n  content: HTMLElement | string;\n  attachedEl?: HTMLElement | null;\n  interactive?: boolean;\n}\n\ninterface TrailCore {\n  steps: Step[];\n  next(): void;\n  back(): void;\n  stop(): void;\n  destroy(): void;\n}\n```\n\n`TrailCore.steps` is just an array, you can use any `Array` functions on this (e.g, `push`, `splice`, `unshift`)\n\n## License\n\nCopyright (c) 2021 Ion. Licensed under [MIT License](LICENSE).\n\n[https://ionited.io](https://ionited.io)\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fionited%2Ftrail","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fionited%2Ftrail","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fionited%2Ftrail/lists"}