diff --git a/.gitignore b/.gitignore index 925c749..79518f7 100644 --- a/.gitignore +++ b/.gitignore @@ -1,2 +1,21 @@ -/.env -__pycache__/ \ No newline at end of file +node_modules + +# Output +.output +.vercel +/.svelte-kit +/build + +# OS +.DS_Store +Thumbs.db + +# Env +.env +.env.* +!.env.example +!.env.test + +# Vite +vite.config.js.timestamp-* +vite.config.ts.timestamp-* diff --git a/.npmrc b/.npmrc new file mode 100644 index 0000000..b6f27f1 --- /dev/null +++ b/.npmrc @@ -0,0 +1 @@ +engine-strict=true diff --git a/.prettierignore b/.prettierignore new file mode 100644 index 0000000..ab78a95 --- /dev/null +++ b/.prettierignore @@ -0,0 +1,4 @@ +# Package Managers +package-lock.json +pnpm-lock.yaml +yarn.lock diff --git a/.prettierrc b/.prettierrc new file mode 100644 index 0000000..9573023 --- /dev/null +++ b/.prettierrc @@ -0,0 +1,8 @@ +{ + "useTabs": true, + "singleQuote": true, + "trailingComma": "none", + "printWidth": 100, + "plugins": ["prettier-plugin-svelte"], + "overrides": [{ "files": "*.svelte", "options": { "parser": "svelte" } }] +} diff --git a/README.md b/README.md index b1a605d..5ce6766 100644 --- a/README.md +++ b/README.md @@ -1,3 +1,38 @@ -# Zauberkiste +# create-svelte -A selfhosted wishlist manager. +Everything you need to build a Svelte project, powered by [`create-svelte`](https://github.com/sveltejs/kit/tree/main/packages/create-svelte). + +## Creating a project + +If you're seeing this, you've probably already done this step. Congrats! + +```bash +# create a new project in the current directory +npm create svelte@latest + +# create a new project in my-app +npm create svelte@latest my-app +``` + +## Developing + +Once you've created a project and installed dependencies with `npm install` (or `pnpm install` or `yarn`), start a development server: + +```bash +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: + +```bash +npm run build +``` + +You can preview the production build with `npm run preview`. + +> To deploy your app, you may need to install an [adapter](https://kit.svelte.dev/docs/adapters) for your target environment. diff --git a/docker-compose.yml b/docker-compose.yml new file mode 100644 index 0000000..f966a42 --- /dev/null +++ b/docker-compose.yml @@ -0,0 +1,17 @@ +version: '3' + +services: + zauberkiste: + build: + context: . + target: dev # Build the development target + ports: + - "5173:5173" + - "24678:24678" + volumes: + - .:/app + - /app/node_modules + - ./data:/app/data + container_name: svelte-app-dev + environment: + NODE_ENV: development diff --git a/dockerfile b/dockerfile new file mode 100644 index 0000000..df6967e --- /dev/null +++ b/dockerfile @@ -0,0 +1,51 @@ +# Stage 1: Base stage +FROM node:18 AS base + +# Set the working directory +WORKDIR /app + +# Copy package.json and package-lock.json +COPY package*.json ./ + +# Install dependencies +RUN npm install + +# Copy the rest of the application files +COPY . . + +# Define build arguments +ARG NODE_ENV +ENV NODE_ENV=$NODE_ENV + +# Stage 2: Development stage +FROM base AS dev + +# Expose ports needed for the development server and hot module reloading +EXPOSE 5173 24678 + +# In development mode, run the dev server +CMD ["npm", "run", "dev", "--", "--host"] + +# Stage 3: Build for production +FROM base AS build + +# Build the Svelte app in production mode +RUN npm run build + +# Stage 4: Production stage +FROM node:18-alpine AS prod + +# Install a lightweight server to serve the production build +RUN npm install -g serve + +# Set the working directory +WORKDIR /app + +# Copy the built files from the build stage +COPY --from=build /app/build /app/build + +# Expose port 5000 for serving the production app +EXPOSE 5000 + +# Serve the production build +CMD ["serve", "-s", "build", "-l", "5000"] diff --git a/eslint.config.js b/eslint.config.js new file mode 100644 index 0000000..39ea393 --- /dev/null +++ b/eslint.config.js @@ -0,0 +1,32 @@ +import eslint from '@eslint/js'; +import prettier from 'eslint-config-prettier'; +import svelte from 'eslint-plugin-svelte'; +import globals from 'globals'; +import tseslint from 'typescript-eslint'; + +export default tseslint.config( + eslint.configs.recommended, + ...tseslint.configs.recommended, + ...svelte.configs['flat/recommended'], + prettier, + ...svelte.configs['flat/prettier'], + { + languageOptions: { + globals: { + ...globals.browser, + ...globals.node + } + } + }, + { + files: ['**/*.svelte'], + languageOptions: { + parserOptions: { + parser: tseslint.parser + } + } + }, + { + ignores: ['build/', '.svelte-kit/', 'dist/'] + } +); diff --git a/package.json b/package.json new file mode 100644 index 0000000..dff1c99 --- /dev/null +++ b/package.json @@ -0,0 +1,32 @@ +{ + "name": "zauberkiste", + "version": "0.0.1", + "private": true, + "scripts": { + "dev": "vite dev", + "build": "vite build", + "preview": "vite preview", + "check": "svelte-kit sync && svelte-check --tsconfig ./tsconfig.json", + "check:watch": "svelte-kit sync && svelte-check --tsconfig ./tsconfig.json --watch", + "lint": "prettier --check . && eslint .", + "format": "prettier --write ." + }, + "devDependencies": { + "@sveltejs/adapter-auto": "^3.0.0", + "@sveltejs/kit": "^2.0.0", + "@sveltejs/vite-plugin-svelte": "^3.0.0", + "@types/eslint": "^9.6.0", + "eslint": "^9.0.0", + "eslint-config-prettier": "^9.1.0", + "eslint-plugin-svelte": "^2.36.0", + "globals": "^15.0.0", + "prettier": "^3.1.1", + "prettier-plugin-svelte": "^3.1.2", + "svelte": "^4.2.7", + "svelte-check": "^4.0.0", + "typescript": "^5.0.0", + "typescript-eslint": "^8.0.0", + "vite": "^5.0.3" + }, + "type": "module" +} diff --git a/requirements.txt b/requirements.txt deleted file mode 100644 index fe22a16..0000000 --- a/requirements.txt +++ /dev/null @@ -1,2 +0,0 @@ -Django>=4.2.7 -mysqlclient \ No newline at end of file diff --git a/src/app.d.ts b/src/app.d.ts new file mode 100644 index 0000000..743f07b --- /dev/null +++ b/src/app.d.ts @@ -0,0 +1,13 @@ +// See https://kit.svelte.dev/docs/types#app +// for information about these interfaces +declare global { + namespace App { + // interface Error {} + // interface Locals {} + // interface PageData {} + // interface PageState {} + // interface Platform {} + } +} + +export {}; diff --git a/src/app.html b/src/app.html new file mode 100644 index 0000000..77a5ff5 --- /dev/null +++ b/src/app.html @@ -0,0 +1,12 @@ + + + + + + + %sveltekit.head% + + +
%sveltekit.body%
+ + diff --git a/src/db.sqlite3 b/src/db.sqlite3 deleted file mode 100644 index f1e11f6..0000000 Binary files a/src/db.sqlite3 and /dev/null differ diff --git a/src/lib/index.ts b/src/lib/index.ts new file mode 100644 index 0000000..856f2b6 --- /dev/null +++ b/src/lib/index.ts @@ -0,0 +1 @@ +// place files you want to import through the `$lib` alias in this folder. diff --git a/src/manage.py b/src/manage.py deleted file mode 100644 index 78ec782..0000000 --- a/src/manage.py +++ /dev/null @@ -1,22 +0,0 @@ -#!/usr/bin/env python -"""Django's command-line utility for administrative tasks.""" -import os -import sys - - -def main(): - """Run administrative tasks.""" - os.environ.setdefault('DJANGO_SETTINGS_MODULE', 'zauberkiste.settings') - try: - from django.core.management import execute_from_command_line - except ImportError as exc: - raise ImportError( - "Couldn't import Django. Are you sure it's installed and " - "available on your PYTHONPATH environment variable? Did you " - "forget to activate a virtual environment?" - ) from exc - execute_from_command_line(sys.argv) - - -if __name__ == '__main__': - main() diff --git a/src/routes/+page.svelte b/src/routes/+page.svelte new file mode 100644 index 0000000..5982b0a --- /dev/null +++ b/src/routes/+page.svelte @@ -0,0 +1,2 @@ +

Welcome to SvelteKit

+

Visit kit.svelte.dev to read the documentation

diff --git a/src/wishlists/__init__.py b/src/wishlists/__init__.py deleted file mode 100644 index e69de29..0000000 diff --git a/src/wishlists/admin.py b/src/wishlists/admin.py deleted file mode 100644 index 8c38f3f..0000000 --- a/src/wishlists/admin.py +++ /dev/null @@ -1,3 +0,0 @@ -from django.contrib import admin - -# Register your models here. diff --git a/src/wishlists/apps.py b/src/wishlists/apps.py deleted file mode 100644 index 0d5575f..0000000 --- a/src/wishlists/apps.py +++ /dev/null @@ -1,6 +0,0 @@ -from django.apps import AppConfig - - -class WishlistsConfig(AppConfig): - default_auto_field = 'django.db.models.BigAutoField' - name = 'wishlists' diff --git a/src/wishlists/handler/__init__.py b/src/wishlists/handler/__init__.py deleted file mode 100644 index e69de29..0000000 diff --git a/src/wishlists/handler/wishlist/__init__.py b/src/wishlists/handler/wishlist/__init__.py deleted file mode 100644 index e69de29..0000000 diff --git a/src/wishlists/handler/wishlist/get_wishlist_handler.py b/src/wishlists/handler/wishlist/get_wishlist_handler.py deleted file mode 100644 index a9d477e..0000000 --- a/src/wishlists/handler/wishlist/get_wishlist_handler.py +++ /dev/null @@ -1,16 +0,0 @@ -from uuid import UUID - -from django.http import Http404 - -from wishlists.models import Wishlist - - -def get_wishlist_by_uuid(uuid: UUID) -> Wishlist: - return Wishlist.objects.get(id=uuid) - - -def get_wishlist_or_404_by_uuid(uuid: UUID) -> Wishlist: - try: - return get_wishlist_by_uuid(uuid) - except Wishlist.DoesNotExist: - raise Http404("This wishlist does not exist.") diff --git a/src/wishlists/migrations/0001_initial.py b/src/wishlists/migrations/0001_initial.py deleted file mode 100644 index 9241fec..0000000 --- a/src/wishlists/migrations/0001_initial.py +++ /dev/null @@ -1,40 +0,0 @@ -# Generated by Django 4.2.7 on 2023-11-27 22:52 - -from django.db import migrations, models -import django.db.models.deletion - - -class Migration(migrations.Migration): - - initial = True - - dependencies = [ - ] - - operations = [ - migrations.CreateModel( - name='Wishlist', - fields=[ - ('id', models.UUIDField(primary_key=True, serialize=False)), - ('name', models.CharField(max_length=200)), - ('description', models.CharField(max_length=2000)), - ('created_at', models.DateTimeField(auto_now_add=True)), - ('updated_at', models.DateTimeField(auto_now=True)), - ], - ), - migrations.CreateModel( - name='WishlistItem', - fields=[ - ('id', models.UUIDField(primary_key=True, serialize=False)), - ('name', models.CharField(max_length=200)), - ('description', models.CharField(max_length=2000)), - ('url', models.CharField(max_length=2000)), - ('price', models.FloatField()), - ('image', models.CharField(blank=True, max_length=2000, null=True)), - ('gifted', models.BooleanField(default=False)), - ('created_at', models.DateTimeField(auto_now_add=True)), - ('updated_at', models.DateTimeField(auto_now=True)), - ('wishlist', models.ForeignKey(on_delete=django.db.models.deletion.CASCADE, to='wishlists.wishlist')), - ], - ), - ] diff --git a/src/wishlists/migrations/0002_alter_wishlist_description_and_more.py b/src/wishlists/migrations/0002_alter_wishlist_description_and_more.py deleted file mode 100644 index dbb0abe..0000000 --- a/src/wishlists/migrations/0002_alter_wishlist_description_and_more.py +++ /dev/null @@ -1,33 +0,0 @@ -# Generated by Django 4.2.7 on 2023-11-27 23:02 - -from django.db import migrations, models - - -class Migration(migrations.Migration): - - dependencies = [ - ('wishlists', '0001_initial'), - ] - - operations = [ - migrations.AlterField( - model_name='wishlist', - name='description', - field=models.CharField(max_length=2000, null=True), - ), - migrations.AlterField( - model_name='wishlistitem', - name='description', - field=models.CharField(max_length=2000, null=True), - ), - migrations.AlterField( - model_name='wishlistitem', - name='price', - field=models.FloatField(null=True), - ), - migrations.AlterField( - model_name='wishlistitem', - name='url', - field=models.CharField(max_length=2000, null=True), - ), - ] diff --git a/src/wishlists/migrations/__init__.py b/src/wishlists/migrations/__init__.py deleted file mode 100644 index e69de29..0000000 diff --git a/src/wishlists/models.py b/src/wishlists/models.py deleted file mode 100644 index 8728651..0000000 --- a/src/wishlists/models.py +++ /dev/null @@ -1,30 +0,0 @@ -from django.db import models - - -class Wishlist(models.Model): - id = models.UUIDField(primary_key=True) - name = models.CharField(max_length=200) - description = models.CharField(max_length=2000, null=True) - created_at = models.DateTimeField(auto_now_add=True) - updated_at = models.DateTimeField(auto_now=True) - - def __str__(self): - return f"{self.name} ({self.id})" - - -class WishlistItem(models.Model): - id = models.UUIDField(primary_key=True) - wishlist = models.ForeignKey(Wishlist, on_delete=models.CASCADE) - name = models.CharField(max_length=200) - description = models.CharField(max_length=2000, null=True) - order = models.IntegerField(null=True) - url = models.CharField(max_length=2000, null=True) - price = models.FloatField(null=True) - image = models.CharField(max_length=2000, blank=True, null=True) - gifted = models.BooleanField(default=False) - reveal_date = models.DateTimeField(null=True) - created_at = models.DateTimeField(auto_now_add=True) - updated_at = models.DateTimeField(auto_now=True) - - def __str__(self): - return f"{self.name} ({self.id})" diff --git a/src/wishlists/templates/owner/index.html b/src/wishlists/templates/owner/index.html deleted file mode 100644 index 1d602cf..0000000 --- a/src/wishlists/templates/owner/index.html +++ /dev/null @@ -1,9 +0,0 @@ -{% if wishlist %} -

{{ wishlist.name }}

- Created on {{ wishlist.created_at }} - {% if wishlist.description %} -

{{ wishlist.description }}

- {% endif %} -{% else %} -

Wishlist not found.

-{% endif %} \ No newline at end of file diff --git a/src/wishlists/templates/public/index.html b/src/wishlists/templates/public/index.html deleted file mode 100644 index 16790fe..0000000 --- a/src/wishlists/templates/public/index.html +++ /dev/null @@ -1,37 +0,0 @@ -{% if wishlist %} -

{{ wishlist.name }}

- Created on {{ wishlist.created_at }} - {% if wishlist.description %} -

{{ wishlist.description }}

- {% endif %} - - Public link - - - - - - - - - - - - - {% for item in wishlist_items %} - - - - - - - - {% endfor %} - -
ItemPriceLinkPriorityActions
{{ item.name }}{{ item.price }}{{ item.link }}{{ item.priority }} - Edit - Delete -
-{% else %} -

Wishlist not found.

-{% endif %} \ No newline at end of file diff --git a/src/wishlists/tests.py b/src/wishlists/tests.py deleted file mode 100644 index 7ce503c..0000000 --- a/src/wishlists/tests.py +++ /dev/null @@ -1,3 +0,0 @@ -from django.test import TestCase - -# Create your tests here. diff --git a/src/wishlists/urls.py b/src/wishlists/urls.py deleted file mode 100644 index be37554..0000000 --- a/src/wishlists/urls.py +++ /dev/null @@ -1,9 +0,0 @@ -from django.urls import path - -from . import views - -urlpatterns = [ - path("public//", views.public, name="public"), - path("owner//", views.owner, name="owner"), - path("", views.index, name="index"), -] diff --git a/src/wishlists/views.py b/src/wishlists/views.py deleted file mode 100644 index 8017973..0000000 --- a/src/wishlists/views.py +++ /dev/null @@ -1,27 +0,0 @@ -from uuid import UUID - -from django.http import HttpResponse, Http404 -from django.template import loader - -from .handler.wishlist.get_wishlist_handler import get_wishlist_or_404_by_uuid -from .models import Wishlist - - -# Create your views here. -def index(request): - return HttpResponse("Hello, world. You're at the wishlists index.") - - -def owner(request, wishlist_id: UUID): - wishlist = get_wishlist_or_404_by_uuid(wishlist_id) - return HttpResponse(f"You are the owner of wishlist '{wishlist.name}'.") - - -def public(request, wishlist_id: UUID): - template = loader.get_template("public/index.html") - wishlist = get_wishlist_or_404_by_uuid(wishlist_id) - context = { - "wishlist": wishlist, - "wishlist_items": wishlist.wishlistitem_set.all(), - } - return HttpResponse(template.render(context, request)) diff --git a/src/zauberkiste/__init__.py b/src/zauberkiste/__init__.py deleted file mode 100644 index e69de29..0000000 diff --git a/src/zauberkiste/asgi.py b/src/zauberkiste/asgi.py deleted file mode 100644 index 95d3ed5..0000000 --- a/src/zauberkiste/asgi.py +++ /dev/null @@ -1,16 +0,0 @@ -""" -ASGI config for zauberkiste project. - -It exposes the ASGI callable as a module-level variable named ``application``. - -For more information on this file, see -https://docs.djangoproject.com/en/4.2/howto/deployment/asgi/ -""" - -import os - -from django.core.asgi import get_asgi_application - -os.environ.setdefault('DJANGO_SETTINGS_MODULE', 'zauberkiste.settings') - -application = get_asgi_application() diff --git a/src/zauberkiste/settings.py b/src/zauberkiste/settings.py deleted file mode 100644 index e342bc0..0000000 --- a/src/zauberkiste/settings.py +++ /dev/null @@ -1,123 +0,0 @@ -""" -Django settings for zauberkiste project. - -Generated by 'django-admin startproject' using Django 4.2.7. - -For more information on this file, see -https://docs.djangoproject.com/en/4.2/topics/settings/ - -For the full list of settings and their values, see -https://docs.djangoproject.com/en/4.2/ref/settings/ -""" - -from pathlib import Path - -# Build paths inside the project like this: BASE_DIR / 'subdir'. -BASE_DIR = Path(__file__).resolve().parent.parent - - -# Quick-start development settings - unsuitable for production -# See https://docs.djangoproject.com/en/4.2/howto/deployment/checklist/ - -# SECURITY WARNING: keep the secret key used in production secret! -SECRET_KEY = "django-insecure-jrs0@9gnu_))f6(%25n30yze^d93#62%l+*8yw+6b^j3_#po9c" - -# SECURITY WARNING: don't run with debug turned on in production! -DEBUG = True - -ALLOWED_HOSTS = [] - - -# Application definition - -INSTALLED_APPS = [ - "wishlists.apps.WishlistsConfig", - "django.contrib.auth", - "django.contrib.contenttypes", - "django.contrib.sessions", - "django.contrib.messages", - "django.contrib.staticfiles", -] - -MIDDLEWARE = [ - "django.middleware.security.SecurityMiddleware", - "django.contrib.sessions.middleware.SessionMiddleware", - "django.middleware.common.CommonMiddleware", - "django.middleware.csrf.CsrfViewMiddleware", - "django.contrib.auth.middleware.AuthenticationMiddleware", - "django.contrib.messages.middleware.MessageMiddleware", - "django.middleware.clickjacking.XFrameOptionsMiddleware", -] - -ROOT_URLCONF = "zauberkiste.urls" - -TEMPLATES = [ - { - "BACKEND": "django.template.backends.django.DjangoTemplates", - "DIRS": [], - "APP_DIRS": True, - "OPTIONS": { - "context_processors": [ - "django.template.context_processors.debug", - "django.template.context_processors.request", - "django.contrib.auth.context_processors.auth", - "django.contrib.messages.context_processors.messages", - ], - }, - }, -] - -WSGI_APPLICATION = "zauberkiste.wsgi.application" - - -# Database -# https://docs.djangoproject.com/en/4.2/ref/settings/#databases - -DATABASES = { - "default": { - "ENGINE": "django.db.backends.sqlite3", - "NAME": BASE_DIR / "db.sqlite3", - } -} - - -# Password validation -# https://docs.djangoproject.com/en/4.2/ref/settings/#auth-password-validators - -AUTH_PASSWORD_VALIDATORS = [ - { - "NAME": "django.contrib.auth.password_validation.UserAttributeSimilarityValidator", - }, - { - "NAME": "django.contrib.auth.password_validation.MinimumLengthValidator", - }, - { - "NAME": "django.contrib.auth.password_validation.CommonPasswordValidator", - }, - { - "NAME": "django.contrib.auth.password_validation.NumericPasswordValidator", - }, -] - - -# Internationalization -# https://docs.djangoproject.com/en/4.2/topics/i18n/ - -LANGUAGE_CODE = "en-us" - -TIME_ZONE = "Europe/Berlin" - -USE_I18N = True - -USE_TZ = True - - -# Static files (CSS, JavaScript, Images) -# https://docs.djangoproject.com/en/4.2/howto/static-files/ - -STATIC_URL = "static/" - -# Default primary key field type -# https://docs.djangoproject.com/en/4.2/ref/settings/#default-auto-field - -DEFAULT_AUTO_FIELD = "django.db.models.BigAutoField" diff --git a/src/zauberkiste/urls.py b/src/zauberkiste/urls.py deleted file mode 100644 index f16d636..0000000 --- a/src/zauberkiste/urls.py +++ /dev/null @@ -1,19 +0,0 @@ -""" -URL configuration for zauberkiste project. - -The `urlpatterns` list routes URLs to views. For more information please see: - https://docs.djangoproject.com/en/4.2/topics/http/urls/ -Examples: -Function views - 1. Add an import: from my_app import views - 2. Add a URL to urlpatterns: path('', views.home, name='home') -Class-based views - 1. Add an import: from other_app.views import Home - 2. Add a URL to urlpatterns: path('', Home.as_view(), name='home') -Including another URLconf - 1. Import the include() function: from django.urls import include, path - 2. Add a URL to urlpatterns: path('blog/', include('blog.urls')) -""" -from django.urls import path, include - -urlpatterns = [path("", include("wishlists.urls"))] diff --git a/src/zauberkiste/wsgi.py b/src/zauberkiste/wsgi.py deleted file mode 100644 index 525d7c0..0000000 --- a/src/zauberkiste/wsgi.py +++ /dev/null @@ -1,16 +0,0 @@ -""" -WSGI config for zauberkiste project. - -It exposes the WSGI callable as a module-level variable named ``application``. - -For more information on this file, see -https://docs.djangoproject.com/en/4.2/howto/deployment/wsgi/ -""" - -import os - -from django.core.wsgi import get_wsgi_application - -os.environ.setdefault('DJANGO_SETTINGS_MODULE', 'zauberkiste.settings') - -application = get_wsgi_application() diff --git a/static/favicon.png b/static/favicon.png new file mode 100644 index 0000000..825b9e6 Binary files /dev/null and b/static/favicon.png differ diff --git a/svelte.config.js b/svelte.config.js new file mode 100644 index 0000000..4a82086 --- /dev/null +++ b/svelte.config.js @@ -0,0 +1,18 @@ +import adapter from '@sveltejs/adapter-auto'; +import { vitePreprocess } from '@sveltejs/vite-plugin-svelte'; + +/** @type {import('@sveltejs/kit').Config} */ +const config = { + // Consult https://kit.svelte.dev/docs/integrations#preprocessors + // for more information about preprocessors + preprocess: vitePreprocess(), + + kit: { + // adapter-auto only supports some environments, see https://kit.svelte.dev/docs/adapter-auto for a list. + // If your environment is not supported, or you settled on a specific environment, switch out the adapter. + // See https://kit.svelte.dev/docs/adapters for more information about adapters. + adapter: adapter() + } +}; + +export default config; diff --git a/tsconfig.json b/tsconfig.json new file mode 100644 index 0000000..fc93cbd --- /dev/null +++ b/tsconfig.json @@ -0,0 +1,19 @@ +{ + "extends": "./.svelte-kit/tsconfig.json", + "compilerOptions": { + "allowJs": true, + "checkJs": true, + "esModuleInterop": true, + "forceConsistentCasingInFileNames": true, + "resolveJsonModule": true, + "skipLibCheck": true, + "sourceMap": true, + "strict": true, + "moduleResolution": "bundler" + } + // Path aliases are handled by https://kit.svelte.dev/docs/configuration#alias + // except $lib which is handled by https://kit.svelte.dev/docs/configuration#files + // + // If you want to overwrite includes/excludes, make sure to copy over the relevant includes/excludes + // from the referenced tsconfig.json - TypeScript does not merge them in +} diff --git a/vite.config.ts b/vite.config.ts new file mode 100644 index 0000000..bbf8c7d --- /dev/null +++ b/vite.config.ts @@ -0,0 +1,6 @@ +import { sveltekit } from '@sveltejs/kit/vite'; +import { defineConfig } from 'vite'; + +export default defineConfig({ + plugins: [sveltekit()] +});