{"id":30698635,"url":"https://github.com/ziv/twoandhalfslash","last_synced_at":"2025-09-02T10:49:52.745Z","repository":{"id":311877187,"uuid":"1045448678","full_name":"ziv/twoandhalfslash","owner":"ziv","description":"twoandhalfslash","archived":false,"fork":false,"pushed_at":"2025-08-27T10:08:59.000Z","size":404,"stargazers_count":0,"open_issues_count":0,"forks_count":0,"subscribers_count":0,"default_branch":"main","last_synced_at":"2025-08-27T15:12:34.831Z","etag":null,"topics":[],"latest_commit_sha":null,"homepage":null,"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/ziv.png","metadata":{"files":{"readme":"readme.md","changelog":null,"contributing":null,"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,"zenodo":null}},"created_at":"2025-08-27T07:28:38.000Z","updated_at":"2025-08-27T10:09:02.000Z","dependencies_parsed_at":"2025-08-27T15:13:04.667Z","dependency_job_id":"a56e06d1-8c5f-4624-bb92-9ef91bff22b2","html_url":"https://github.com/ziv/twoandhalfslash","commit_stats":null,"previous_names":["ziv/twoandhalfslash"],"tags_count":null,"template":false,"template_full_name":null,"purl":"pkg:github/ziv/twoandhalfslash","repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/ziv%2Ftwoandhalfslash","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/ziv%2Ftwoandhalfslash/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/ziv%2Ftwoandhalfslash/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/ziv%2Ftwoandhalfslash/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/ziv","download_url":"https://codeload.github.com/ziv/twoandhalfslash/tar.gz/refs/heads/main","sbom_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/ziv%2Ftwoandhalfslash/sbom","scorecard":null,"host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":273272575,"owners_count":25075982,"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-02T02:00:09.530Z","response_time":77,"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":"2025-09-02T10:49:37.024Z","updated_at":"2025-09-02T10:49:52.730Z","avatar_url":"https://github.com/ziv.png","language":"JavaScript","funding_links":[],"categories":[],"sub_categories":[],"readme":"\u003cdiv align=\"center\"\u003e\n\n\u003ch1\u003e//^\u003c/h1\u003e\n\u003ci\u003etwo and a half slashes\u003c/i\u003e\n\u003c/div\u003e\n\n\n---\n\nA [Siki](https://siki.dev) extension for annotating code with\n_**twoandhalfslash**_ comments.\n\n## Usage\n\n```shell\nnpm instsall twoandhalfslash\n```\n\nAdd transformer to your Shiki config:\n\n```javascript\nimport {codeToHtml} from \"shiki\";\n\nconst html = codeToHtml(code, {\n    theme: \"github-light\",\n    lang: \"javascript\",\n    transformers: [\n        twoandhalfslash(),\n    ],\n});\n```\n\n## Syntax\n\n* Start a comment (prefix) with `//^` (two slashes, a caret, and a space).\n* After the prefix, the command is annotated in square brackets `[]`.\n* The arguments are separated by carets `^`.\n* The first argument is the command name.\n\n```\n//^ [command^arg1^arg2^...]\n```\n\nAll annotations require additional CSS to be applied.\n\n#### Banner\n\nAdd a block element with the content will replace the comment. Add `ths-banner` class to the parent element.\n\n```javascript\n//^ [b^content]\n```\n\n#### Floating Label\n\nAdd a floating label to an element under the cursor (`^`). Add `ths-floater` class to the parent element.\n\n```javascript\nconst date = new Date();\n//^ [f^..........^content]\n```\n\n#### Linker\n\nConvert text into a link. First argument is the text to be converted, second argument is the URL, and a third argument\nis the link title.\n\n```javascript\nconst arr = new Int8Array(10);\n//^ [l^Int8Array^https://developer.mozilla.org^check out docs]\n```\n\n### Example\n\nThe results of the above examples with CSS applied:\n\n![Example of twoandhalfslash extension](./assets/example.png)","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fziv%2Ftwoandhalfslash","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fziv%2Ftwoandhalfslash","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fziv%2Ftwoandhalfslash/lists"}