01 · Context
The problem
Manual registers and spreadsheet-based inventory make it difficult to see stock, track usage, preserve an audit trail and manage equipment consistently. ChemStock turns those operations into a shared web workflow.
02 · Product
How it works
ChemStock uses Firebase Authentication and Firestore with role-aware access, inventory and equipment modules, activity logs, reporting, backup/restore and PubChem search. The repository also contains real product screenshots and documents the distinction between admin and regular-user capabilities.
Chemical inventory supports search, filtering, sorting, usage and stock-state visibility.
Equipment includes checkout, return and damaged-item workflows.
Activity logs provide a user-wise audit trail of inventory actions.
Admin workflows cover reports, CSV export, database backup and restore.
PubChem search brings chemical structures, properties and safety data into the product.
The app is responsive and configured as a PWA.
03 · Architecture
The system, broken down
Authentication
Firebase Authentication supports email/password and Google Sign-In, with allow-list and admin-email configuration documented in the repository.
Application
Next.js App Router contains protected auth routes, dashboard routes, chemical/equipment views and admin modules.
Data
Firestore is the primary persistence layer for inventory, equipment, activity and related application records.
External data
PubChem is integrated for chemical information lookup; the repository also contains AI/Genkit scaffolding.
Operations
Reports, CSV exports and JSON backup/restore give admins operational tools beyond CRUD screens.
04 · Flow
A request through the system
Sign in
A user authenticates through Firebase and enters the role-appropriate dashboard.
Find
Chemicals and equipment can be searched, filtered and sorted from the inventory views.
Use
Users can record chemical usage or check out/return equipment within the documented permissions.
Audit
Activity data and reports provide visibility into operational changes.
Administer
Admins can edit inventory, export data and manage backup/restore operations.
05 · Engineering
Decisions worth noticing
Role-based editing
Regular users can use inventory without receiving unrestricted edit access; admins can explicitly enter edit mode.
Firestore for shared state
A real-time cloud database fits a lab workflow where inventory state is shared across users.
Operational depth
Reports, audit logs, backup/restore and reorder workflows make the project more than a simple inventory CRUD app.
Real chemical reference
Integrating PubChem keeps chemistry metadata inside the system instead of forcing users to leave the workflow.
06 · Proof
From the actual project






Scope note
The uploaded README states that ChemStock is actively used in a college chemistry laboratory; this case study preserves that claim without adding invented adoption or performance numbers.