Sveltekit Platforms Starter Template
A simple starter template for building platforms on Vercel.
Summary
Sveltekit Platforms is your starting point for developing a full scalable platforms implementation built with your favorite framework on Vercel. This is intended to be a simple template and can be extended in many ways to unlock even more.
To get started, deploy to Vercel using the button above and clone the repo. Each "app" can be found in the /lib/apps
folder. This version uses the subdomain of the url host to determine which app components to render in real time.
Example
Each subdomain above maps to an app in the /lib/apps
folder.
The config.js file contains the page mappings needed to create more pages in your app. For example, this mapping in app1 the About page is mapped to the About.svelte component.
More docs coming soon...
Developing
The APP_ID
environment variable is required for local development and is used to switch context between apps. Find an example here.
Once you've created a project and installed dependencies with npm install
(or pnpm install
or yarn
), start a development server:
npm run dev
# or start the server and open the app in a new browser tab
npm run dev -- --open
Building
To create a production version of your app:
npm run build
You can preview the production build with npm run preview
.