-
Notifications
You must be signed in to change notification settings - Fork 1
Open
Milestone
Description
Description
Restructure the project into a monorepo layout to support separate desktop and mobile frontends while sharing types, stores, API wrappers, utilities, and i18n.
This must happen before any mobile frontend code is written.
Scope:
- Move
src/toapps/desktop/src/ - Extract shared code to
shared/:types/β all TypeScript type definitionsapi/β all Tauri IPC wrappers (sameinvoke()calls used by both platforms)stores/β shared stores: discovery, discoveryPlaylist, expandedReleases, player, tags, playlists, settings, toastutils/β format, sorting, selection, storage, artwork utilitiesi18n/β all locale files and i18n setupservices/previewPlayer.tsβ HTML5 Audio singleton
- Desktop-only stores stay in
apps/desktop/src/lib/stores/: devices, export, sync (USB), analysis, drag, app, crash, diagnostics, missingTracks, updater, splash, backup, pageActions - Desktop-only components, controllers, and hooks stay in
apps/desktop/ - Update Tauri configs (
tauri.conf.json,tauri.dev.conf.json, etc.) to point toapps/desktop/ - Add
$sharedpath alias in bothsvelte.config.jsandvite.config.tspointing to../../shared/ - Scaffold
apps/mobile/with SvelteKit, ownsvelte.config.js,vite.config.ts, same$sharedalias - Update all import paths throughout the desktop frontend
- Verify desktop build works identically after restructuring
Key files:
src/βapps/desktop/src/shared/β new directoryapps/mobile/β new scaffolded directorysvelte.config.js,vite.config.tsβ both appssrc-tauri/tauri.conf.jsonand environment-specific configs
Open questions
- Should the root
package.jsonuse Yarn workspaces, or keep a singlepackage.jsonwith path aliases only? - Should
svelte.config.jsandvite.config.tslive inapps/desktop/or remain at root with the mobile equivalents added alongside? - Should the
uistore be split (shared core state vs. desktop-specific layout state) or kept entirely in desktop?
Acceptance criteria
- Desktop application builds and runs identically after restructuring (no functional changes)
apps/desktop/src/contains only desktop-specific code (components, controllers, hooks, desktop-only stores)shared/contains types, API wrappers, shared stores, utils, i18n, and previewPlayer serviceapps/mobile/is scaffolded with SvelteKit and can import from$shared- All import paths are updated and resolve correctly
src-tauri/is unchanged in location and continues to serve both platforms- Tauri configs correctly reference
apps/desktop/for frontend
Tasks
TBD
Reactions are currently unavailable
Metadata
Metadata
Assignees
Labels
No labels