Svelte Commerce
A standalone open-source storefront built with SvelteKit, headless across 26 commerce backends. MIT licensed.
翻譯準備中
尚未偵測到更新。GitHub 發布版本後會顯示在這裡。
個人 GitHub 帳號下公開儲存庫的擁有者可以登入並驗證所有權,自行管理介紹,無需管理員核准。
登入並產生驗證檔案,在 30 分鐘內將其提交至此儲存庫的預設分支。其他分支或分叉儲存庫中的檔案無效。然後在下方檢查檔案,即可無需管理員核准直接管理專案。請保留檔案以維持管理權限。
如需登入,將前往登入頁面。登入後請回到此處,再次點擊所選的驗證按鈕。
在專案資料夾中執行 /nomorevibe verify,即可驗證所有權並自行管理介紹。
一分鐘完成驗證Bilingual (Arabic/English) inventory & finance system for merchants — one transactional posting engine keeps stock, landed cost, ledgers & profit in sync. Next.js 16 · React 19 · TypeScript · Prisma · NextAuth. Salla & Fast Hub (3PL) integrations.
翻譯準備中
取自儲存庫 README
正在載入完整 README。
檢視完整 README ↗A bilingual (Arabic / English) inventory and financial management system for merchants, where every transaction updates stock, landed cost, ledgers, and profit in one atomic operation.
Built with Next.js 16 (App Router), React 19, TypeScript, Prisma, and NextAuth. Arabic-first and fully right-to-left, with English as a second locale.
Small and mid-size merchants usually run inventory in one tool and finances in another — often spreadsheets — so stock levels, landed costs, cash balances, and profit never reconcile. A sale is recorded in one place, the cost of what was sold in another, and the "real" profit is a guess at month-end.
Tijarah Smart removes the gap: a sale, purchase, stock movement, expense, or payment is posted once, through a single transactional service that updates inventory, account balances, cost, and profit together — and every number stays traceable to the transaction behind it. There are no disconnected pages and no placeholder dashboards.
It's built for real retail / e-commerce operations in the Arabic-speaking market, including Salla and 3PL (Fast Hub / Omniful) integration.
messages/ar.json, messages/en.json).AUTH_SECRET).A modular monolith: a Next.js App Router front end over a set of server-side services, with one transactional posting engine as the single writer of financial state.
flowchart TD
subgraph Client["Browser — Next.js App Router (AR / RTL · EN)"]
UI["React 19 Server + Client Components<br/>next-intl i18n"]
end
subgraph Server["Next.js server"]
SA["Server Actions / Route Handlers<br/>Zod validation"]
AUTH["NextAuth v5<br/>membership re-checked per mutation"]
SVC["Posting engine — src/services/<br/>one atomic transaction + audit log"]
CRYPTO["src/lib/crypto.ts<br/>encrypts stored credentials"]
end
DB[("Prisma 7<br/>SQLite · PostgreSQL-portable")]
SALLA["Salla OAuth API"]
FASTHUB["Fast Hub / Omniful 3PL"]
UI -->|request| SA
SA --> AUTH
SA --> SVC
SVC -->|"inventory · ledgers · cost · profit<br/>(single transaction)"| DB
SVC --> CRYPTO
CRYPTO --> DB
SVC <-->|sync orders / costs| SALLA
SVC <-->|fulfilment| FASTHUB
Design decisions that matter (see docs/decisions.md):
| Layer | Technology |
|---|---|
| Framework | Next.js 16 (App Router), React 19 |
| Language | TypeScript |
| Styling | Tailwind CSS 4 |
| Data | Prisma 7 + better-sqlite3 (PostgreSQL-portable schema) |
| Auth | NextAuth v5 |
| i18n | next-intl (Arabic RTL + English) |
| Validation | Zod |
| Exports | ExcelJS |
| Tests | Vitest + Testing Library |
| Deploy | Caddy (auto-TLS) + systemd |
npm install
cp .env.example .env # then set AUTH_SECRET: openssl rand -base64 48
npm run db:push # apply the Prisma schema to the database
npm run seed # build a demo company (safe to re-run)
npm run dev
The app runs at http://localhost:3000, with locales /ar (default, RTL) and /en.
The seed creates a demo company. Default owner login: [email protected] / demo12345 (other roles are in prisma/seed.ts).
| Command | What it does |
|---|---|
npm run dev | Development server |
npm run build | Production build |
npm test | Full test suite (Vitest) |
npm run lint | ESLint |
npm run db:push | Apply prisma/schema.prisma to the database |
npm run seed | Rebuild the demo company |
Add screenshots here.
| Dashboard (occupancy of cash, stock, profit) | docs/screenshots/dashboard.png |
| New sale (bilingual, RTL) | docs/screenshots/sale.png |
| Inventory / warehouses | docs/screenshots/inventory.png |
| Profit & finance | docs/screenshots/profit.png |
What this project taught me
Roadmap (Stage 1 — the core merchant loop — is complete; later stages are planned)
Status: Stage 1 (register → company setup → products → receive/sell/transfer/count → expenses/payments → accurate profit, cash, and customer/supplier balances) is complete and covered by the test suite.
Released under the MIT License.