Kitchen Inventory
All Projects
Tauri SvelteKit SQLite Rust

Kitchen Inventory

Cross-platform desktop app for tracking home kitchen inventory

01

Overview

Kitchen Inventory is a native desktop application built with Tauri and SvelteKit that helps households track pantry items, set expiry-date alerts, and generate shopping lists. It runs offline-first with a local SQLite database, meaning no account sign-up or internet connection is required.

02

Problem & Solution

The Problem

Households regularly buy duplicate groceries or throw away expired food because there is no easy way to see what is already in the pantry. Cloud-based inventory apps require an account and a network connection, which is unnecessary friction for a personal utility.

The Solution

Built a lightweight desktop application that stores all data in a local SQLite file via Tauri's Rust backend. The SvelteKit frontend communicates with the Rust layer through Tauri's typed command API, giving a web-development workflow while shipping a native binary with a tiny footprint (~10 MB installer).

03

Tech Stack

Tauri

Tauri wraps a native WebView around a Rust backend, producing installers dramatically smaller than Electron (< 10 MB vs. 100+ MB). The Rust layer handles file-system access and SQLite via rusqlite, keeping sensitive operations out of the JavaScript context.

SvelteKit

Svelte compiles away the framework at build time, producing minimal JS. Its reactive stores map naturally to real-time UI updates when inventory quantities change. SvelteKit's file-based routing structures the app's views cleanly.

SQLite (via rusqlite)

A single-file database is ideal for a personal desktop app — no server process, easy to backup by copying one file, and sufficient for thousands of inventory records with sub-millisecond queries.

Rust

Tauri's backend commands are written in Rust, providing memory safety and performance for file I/O and database operations without a runtime dependency on Node.js or Python.

04

Key Features

  • Add, edit, and delete pantry items with quantity and unit
  • Expiry-date tracking with colour-coded alerts (fresh / expiring soon / expired)
  • Category organisation (dairy, produce, dry goods, etc.)
  • Auto-generated shopping list from low-stock items
  • Full offline operation — no account or internet required
  • Cross-platform: Windows, macOS, and Linux installers
  • Data stored in a portable SQLite file (easy backup)
05

Challenges & Learnings

#01

Bridging Svelte and Rust

Tauri's invoke API is asynchronous. Designing a clean abstraction layer that wraps Tauri commands in typed TypeScript functions — and handles errors uniformly — took careful API design to avoid callback complexity in the Svelte components.

#02

SQLite migrations in a desktop context

Unlike a server app, users may skip versions when updating. Implementing a lightweight migration runner in Rust that applies pending schema migrations on startup — without an ORM — required writing raw SQL migration files and tracking applied versions in a meta table.

#03

Packaging for multiple platforms

Each target OS requires a different signing and packaging setup (MSI for Windows, DMG for macOS, AppImage for Linux). Setting up GitHub Actions to cross-compile and sign on all three platforms added significant CI complexity.