{"id":16792006,"url":"https://github.com/metonym/template-lib-svelte","last_synced_at":"2026-05-09T03:33:06.427Z","repository":{"id":98413269,"uuid":"234952709","full_name":"metonym/template-lib-svelte","owner":"metonym","description":"Template for building Svelte component libraries","archived":false,"fork":false,"pushed_at":"2020-04-01T15:07:46.000Z","size":319,"stargazers_count":2,"open_issues_count":0,"forks_count":0,"subscribers_count":3,"default_branch":"master","last_synced_at":"2025-09-17T23:55:53.817Z","etag":null,"topics":["component-library","rollup","svelte","template","webpack"],"latest_commit_sha":null,"homepage":null,"language":"JavaScript","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/metonym.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":"LICENSE","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-01-19T19:23:16.000Z","updated_at":"2020-09-06T19:46:34.000Z","dependencies_parsed_at":"2023-03-18T23:02:08.678Z","dependency_job_id":null,"html_url":"https://github.com/metonym/template-lib-svelte","commit_stats":null,"previous_names":[],"tags_count":2,"template":true,"template_full_name":null,"purl":"pkg:github/metonym/template-lib-svelte","repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/metonym%2Ftemplate-lib-svelte","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/metonym%2Ftemplate-lib-svelte/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/metonym%2Ftemplate-lib-svelte/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/metonym%2Ftemplate-lib-svelte/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/metonym","download_url":"https://codeload.github.com/metonym/template-lib-svelte/tar.gz/refs/heads/master","sbom_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/metonym%2Ftemplate-lib-svelte/sbom","scorecard":null,"host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":286080680,"owners_count":32805934,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2026-05-08T08:22:46.396Z","status":"online","status_checked_at":"2026-05-09T02:00:06.633Z","response_time":123,"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":["component-library","rollup","svelte","template","webpack"],"created_at":"2024-10-13T08:43:51.500Z","updated_at":"2026-05-09T03:33:06.412Z","avatar_url":"https://github.com/metonym.png","language":"JavaScript","funding_links":[],"categories":[],"sub_categories":[],"readme":"# template-lib-svelte\n\n[![Build Status](https://travis-ci.com/metonym/template-lib-svelte.svg?branch=master)](https://travis-ci.com/metonym/template-lib-svelte)\n[![codecov](https://img.shields.io/codecov/c/github/metonym/template-lib-svelte.svg)](https://codecov.io/gh/metonym/template-lib-svelte)\n\n\u003e Template for building Svelte component libraries.\n\n## Workflow\n\n- **Development**: develop the library using a webpack set-up ([`app/`](app/))\n- **Testing**: unit test the library using [Jest](https://github.com/facebook/jest) and [@testing-library/svelte](https://github.com/testing-library/svelte-testing-library)\n- **Building**: build the library using [Rollup](https://github.com/rollup/rollup) to support ES/UMD formats\n- **Publishing**: publish the library to [NPM](https://www.npmjs.com/)\n- **Documentation**: deploy the compiled webpack set-up to [GitHub Pages](https://pages.github.com/)\n\n## Getting Started\n\nClone the repository:\n\n```bash\ngit clone git@github.com:metonym/template-lib-svelte.git\ncd template-lib-svelte\n```\n\nInstall its dependencies:\n\n```bash\nyarn install\n```\n\n## Development\n\nWhen developing, use the webpack app set-up in the `app/` folder to reload any changes to the library.\n\n```bash\ncd app\nyarn install\nyarn start\n```\n\n## Available Scripts\n\n### `yarn build`\n\nBuilds the library for production using [Rollup](https://github.com/rollup/rollup) and outputs artifacts to the `lib` folder.\n\n#### Build Formats\n\n```js\n// package.json\n{\n  \"svelte\": \"src/index.js\", // preferred Svelte entry\n  \"main\": \"lib/index.js\", // UMD build\n  \"module\": \"lib/index.mjs\" // ES Module build\n}\n```\n\n### `yarn test`\n\nRuns tests using [Jest](https://github.com/facebook/jest) with [@testing-library/svelte](https://github.com/testing-library/svelte-testing-library) and generates a coverage report.\n\n### `yarn test:tdd`\n\nRuns tests in watch mode.\n\n## Publishing to `npm`\n\n### 1) Update the Library Name\n\nUpdate the library name in [package.json](package.json) and [rollup.config.js](rollup.config.js).\n\n```diff\n{\n- \"name\": \"template-lib-svelte\",\n+ \"name\": \"\u003cYOUR_LIBRARY_NAME\u003e\"\n}\n```\n\n```diff\n// rollup.config.js\nif (UMD) {\n- output.name = 'template-lib-svelte';\n+ output.name = '\u003cYOUR_LIBRARY_NAME\u003e';\n}\n```\n\n## License\n\n[MIT](LICENSE)\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fmetonym%2Ftemplate-lib-svelte","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fmetonym%2Ftemplate-lib-svelte","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fmetonym%2Ftemplate-lib-svelte/lists"}