{"id":15386668,"url":"https://github.com/zerodevx/svelte-component","last_synced_at":"2025-08-31T03:32:24.055Z","repository":{"id":93487702,"uuid":"294653383","full_name":"zerodevx/svelte-component","owner":"zerodevx","description":"An opinionated Svelte component starter template","archived":false,"fork":false,"pushed_at":"2021-04-20T09:28:36.000Z","size":26,"stargazers_count":0,"open_issues_count":0,"forks_count":0,"subscribers_count":2,"default_branch":"master","last_synced_at":"2025-06-10T23:47:46.238Z","etag":null,"topics":[],"latest_commit_sha":null,"homepage":"","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/zerodevx.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}},"created_at":"2020-09-11T09:35:57.000Z","updated_at":"2021-04-20T09:26:41.000Z","dependencies_parsed_at":null,"dependency_job_id":"4f6dc1a4-6304-4d20-9b06-7320826064bd","html_url":"https://github.com/zerodevx/svelte-component","commit_stats":{"total_commits":19,"total_committers":1,"mean_commits":19.0,"dds":0.0,"last_synced_commit":"7249f3a5e0ec55f2fd87c97c4823e071d74c37ae"},"previous_names":[],"tags_count":4,"template":false,"template_full_name":null,"purl":"pkg:github/zerodevx/svelte-component","repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/zerodevx%2Fsvelte-component","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/zerodevx%2Fsvelte-component/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/zerodevx%2Fsvelte-component/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/zerodevx%2Fsvelte-component/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/zerodevx","download_url":"https://codeload.github.com/zerodevx/svelte-component/tar.gz/refs/heads/master","sbom_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/zerodevx%2Fsvelte-component/sbom","scorecard":null,"host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":272934303,"owners_count":25017832,"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-08-31T02:00:09.071Z","response_time":79,"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":"2024-10-01T14:50:08.408Z","updated_at":"2025-08-31T03:32:24.036Z","avatar_url":"https://github.com/zerodevx.png","language":"JavaScript","funding_links":[],"categories":[],"sub_categories":[],"readme":"# svelte-component\n\nAn opinionated starter template to create shareable Svelte components, featuring:\n\n- [x] Linting with [Standardjs](https://github.com/standard/standard)\n- [x] Workflow for local development cum demo site\n\n## Usage\n\nClone with [degit](https://github.com/Rich-Harris/degit) and install dependencies\n\n```bash\n$ npx degit zerodevx/svelte-component my-component\n$ cd my-component\n$ npm i\n```\n\nYour component's source code lives in `src/Component.svelte`.\n\nYou can create a package that exports multiple components by adding them to the `src` directory and editing `src/index.js` to reexport them as named exports.\n\n## Develop your component\n\nStart the server:\n\n```bash\n$ npm run dev\n```\n\nThis serves the `/docs` directory at `http://localhost:5000`, and doubles-up as a demo site as well via Github Pages.\n\n## Consuming components\n\nYour package.json has a `\"svelte\"` field pointing to `src/index.js`, which allows Svelte apps to import the source code directly, if they are using a bundler plugin like [rollup-plugin-svelte](https://github.com/sveltejs/rollup-plugin-svelte) or [svelte-loader](https://github.com/sveltejs/svelte-loader) (where [`resolve.mainFields`](https://webpack.js.org/configuration/resolve/#resolve-mainfields) in your webpack config includes `\"svelte\"`). **This is recommended.**\n\nFor everyone else, `npm run build` will bundle your component's source code into a plain JavaScript module (`dist/index.mjs`) and a UMD script (`dist/index.js`). This will happen automatically when you publish your component to npm, courtesy of the `prepublishOnly` hook in package.json.\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fzerodevx%2Fsvelte-component","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fzerodevx%2Fsvelte-component","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fzerodevx%2Fsvelte-component/lists"}