{"id":23174580,"url":"https://github.com/vscodeshift/snippets-extension-skeleton","last_synced_at":"2025-04-05T00:43:26.170Z","repository":{"id":40783788,"uuid":"235034738","full_name":"vscodeshift/snippets-extension-skeleton","owner":"vscodeshift","description":"skeleton for a VSCode extension that provides snippets","archived":false,"fork":false,"pushed_at":"2023-01-05T05:19:06.000Z","size":3450,"stargazers_count":0,"open_issues_count":20,"forks_count":0,"subscribers_count":2,"default_branch":"master","last_synced_at":"2025-02-10T09:15:15.532Z","etag":null,"topics":[],"latest_commit_sha":null,"homepage":null,"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/vscodeshift.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":"2020-01-20T06:36:00.000Z","updated_at":"2020-02-02T06:13:24.000Z","dependencies_parsed_at":"2023-02-03T13:00:26.656Z","dependency_job_id":null,"html_url":"https://github.com/vscodeshift/snippets-extension-skeleton","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/vscodeshift%2Fsnippets-extension-skeleton","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/vscodeshift%2Fsnippets-extension-skeleton/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/vscodeshift%2Fsnippets-extension-skeleton/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/vscodeshift%2Fsnippets-extension-skeleton/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/vscodeshift","download_url":"https://codeload.github.com/vscodeshift/snippets-extension-skeleton/tar.gz/refs/heads/master","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":247271492,"owners_count":20911586,"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":[],"created_at":"2024-12-18T05:30:14.503Z","updated_at":"2025-04-05T00:43:26.140Z","avatar_url":"https://github.com/vscodeshift.png","language":"TypeScript","funding_links":[],"categories":[],"sub_categories":[],"readme":"# snippets-extension-skeleton\n\n[![CircleCI](https://circleci.com/gh/vscodeshift/snippets-extension-skeleton.svg?style=svg)](https://circleci.com/gh/vscodeshift/snippets-extension-skeleton)\n[![Coverage Status](https://codecov.io/gh/vscodeshift/snippets-extension-skeleton/branch/master/graph/badge.svg)](https://codecov.io/gh/vscodeshift/snippets-extension-skeleton)\n[![semantic-release](https://img.shields.io/badge/%20%20%F0%9F%93%A6%F0%9F%9A%80-semantic--release-e10079.svg)](https://github.com/semantic-release/semantic-release)\n[![Commitizen friendly](https://img.shields.io/badge/commitizen-friendly-brightgreen.svg)](http://commitizen.github.io/cz-cli/)\n[![Visual Studio Marketplace Version](https://img.shields.io/visual-studio-marketplace/v/vscodeshift.snippets-extension-skeleton)](https://marketplace.visualstudio.com/items?itemName=vscodeshift.snippets-extension-skeleton)\n\nskeleton for a VSCode extension that provides snippets\n\n# How to use this skeleton\n\nInstead of typing up the snippets JSON file manually (because it sucks),\nyou define each snippet in a file in `src/snippets/\u003clanguage\u003e/\u003ckey\u003e.ts`.\n\nThe build scripts will then compile these files into the JSON that VSCode\nunderstands and add the `contributes.snippets` entry to `package.json`.\n\nFor [example](./src/snippets/javascript/example.ts):\n\n```ts\n// optional, defaults to filename without extension\nexport const prefix = 'example'\n\nexport const description = 'An example snippet'\n\n// The build tools will strip off the leading and trailing newlines so that you\n// don't have to indent anything.\nexport const body = `\nexport default function $1() {\n  $0\n}\n`\n```\n\nOutput:\n\n```\n{\n  \"example\": {\n    \"prefix\": \"example\",\n    \"description\": \"An example snippet\",\n    \"body\": [\n      \"export default function $1() {\",\n      \"  $0\",\n      \"}\"\n    ]\n  }\n}\n```\n\n# Snippets\n\n\u003c!-- snippets --\u003e\n\n## javascript\n\n### `example`: An example snippet\n\n```\nexport default function $1() {\n  $0\n}\n```\n\n\u003c!-- snippetsend --\u003e\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fvscodeshift%2Fsnippets-extension-skeleton","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fvscodeshift%2Fsnippets-extension-skeleton","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fvscodeshift%2Fsnippets-extension-skeleton/lists"}