{"id":19664891,"url":"https://github.com/small-tech/sitekit","last_synced_at":"2026-06-05T20:31:54.673Z","repository":{"id":117560768,"uuid":"356839082","full_name":"small-tech/sitekit","owner":"small-tech","description":"A template for creating your own Site.js + SvelteKit app.","archived":false,"fork":false,"pushed_at":"2021-04-11T16:12:07.000Z","size":17,"stargazers_count":2,"open_issues_count":1,"forks_count":0,"subscribers_count":4,"default_branch":"main","last_synced_at":"2025-01-10T02:24:34.194Z","etag":null,"topics":[],"latest_commit_sha":null,"homepage":"","language":"Svelte","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"other","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/small-tech.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":"2021-04-11T10:39:04.000Z","updated_at":"2022-01-21T10:34:30.000Z","dependencies_parsed_at":null,"dependency_job_id":"1631b9cd-008d-4b76-8db8-77503bcb1217","html_url":"https://github.com/small-tech/sitekit","commit_stats":null,"previous_names":[],"tags_count":0,"template":true,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/small-tech%2Fsitekit","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/small-tech%2Fsitekit/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/small-tech%2Fsitekit/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/small-tech%2Fsitekit/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/small-tech","download_url":"https://codeload.github.com/small-tech/sitekit/tar.gz/refs/heads/main","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":240974473,"owners_count":19887302,"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-11-11T16:19:32.287Z","updated_at":"2025-02-27T03:43:25.470Z","avatar_url":"https://github.com/small-tech.png","language":"Svelte","funding_links":[],"categories":[],"sub_categories":[],"readme":"# SiteKit\n\nThis template will help get you started developing with [SvelteKit](https://kit.svelte.dev) in [Site.js](https://sitejs.org).\n\nIt’s based on the [`create-svelte`](https://github.com/sveltejs/kit/tree/master/packages/create-svelte) template.\n\n__Note:__ if you want to use vanilla Vite + Svelte instead of SvelteKit, check out the [site-vite-svelte](https://github.com/small-tech/site-vite-svelte) template instead. This template also has the advantage, currently, of running the dev server on https://localhost:444 instead of http://localhost:3000. We can’t do that with SvelteKit’s dev server (yet?) as [it doesn’t currently run correctly with HMR over https](https://github.com/sveltejs/kit/issues/844) and [there isn’t a way to set the `server` property directly on its Vite instance](https://github.com/sveltejs/kit/issues/844#issuecomment-817287992).\n\n## Why?\n\nBy using [Site.js](https://sitejs.org) you can extend your static SvelteKit clients using dynamic [DotJS](https://sitejs.org/#dynamic-sites) routes, [WebSockets](https://sitejs.org/#websockets), [a JavaScript database](https://sitejs.org/#database), etc., and easily deploy to your own server using the [built-in sync feature](https://github.com/small-tech/site.js#sync).\n\n## Install\n\n1. ### __Either:__\n\n    _Download the template:_\n\n    ```shell\n    npm init using small-tech/sitekit my-project\n    ```\n\n    This will download this template using [create-using](https://github.com/aral/create-using/tree/create-using#readme) into a directory called `my-project`.\n\n    ### __Or__:\n\n    _Use the template on GitHub:_\n\n    Click the green “Use this template” button on [the GitHub page](https://github.com/small-tech/sitekit) to create your own repository using this template.\n\n    ### __Or__:\n\n    _Do it old-skool:_\n\n    Just fork this repository and clone it as you normally do using `git`.\n\n2. ### __Install dependencies.__\n\n    ```shell\n    cd my-project\n    npm i\n    ```\n\n## Use\n\n### Dev (Site.js + SvelteKit)\n\n```shell\nnpm run dev\n```\n\nThis will run the `dev.sh` script that:\n\n1. Will build the latest SvelteKit source using `npx svelte-kit build`\n2. Start the SvelteKit dev server in the background\n3. Start Site.js.\n\nOnce the servers are running, you will have:\n\n  - __SvelteKit:__ Running at `http://localhost:3000` with HMR.\n  - __Site.js:__ Running at `https://localhost` with all features (including serving dynamic [DotJS](https://sitejs.org/#dynamic-sites) routes and [WebSockets](https://sitejs.org/#websockets), etc.)\n\nNote that the SvelteKit build is _not_ automatically updated when hitting the Site.js endpoint. To update it, run the build command (see below).\n\nAlso note that the `dev.sh` script will only run on Linux-esque systems. If you’re on Windows, please run the commands listed above manually. Pull requests are welcome for a `dev-windows` task that runs a PowerShell script to do the same thing.\n\n### SvelteKit only\n\n```shell\nnpm run kit\n```\n\nThis will run the SvelteKit dev server _only_ (not Site.js) at `http://localhost:3000`.\n\n### Build\n\n```shell\nnpm run build\n```\n\nThis will build the SvelteKit source into the `.generated` folder that is served by Site.js.\n\n### Serve\n\n```shell\nnpm run serve\n```\n\nThis will:\n\n1. Build the latest Vite source using `vite build`\n2. Serve the site using Site.js.\n\nHit `https://localhost` to view and test your site.\n\n_Note that the Vite dev server will not be run. If that’s what you want, please run the dev task._\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fsmall-tech%2Fsitekit","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fsmall-tech%2Fsitekit","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fsmall-tech%2Fsitekit/lists"}