Ecosyste.ms: Awesome
An open API service indexing awesome lists of open source software.
https://github.com/uros-5/bookstore
Bookstore web application. Buy, rate and comment on books.
https://github.com/uros-5/bookstore
alpiinejs alpine bootstrap css django htmx javascript python sqlite
Last synced: 1 day ago
JSON representation
Bookstore web application. Buy, rate and comment on books.
- Host: GitHub
- URL: https://github.com/uros-5/bookstore
- Owner: uros-5
- Created: 2020-10-05T17:04:57.000Z (about 4 years ago)
- Default Branch: master
- Last Pushed: 2023-09-04T16:48:33.000Z (about 1 year ago)
- Last Synced: 2024-10-12T23:11:06.741Z (about 1 month ago)
- Topics: alpiinejs, alpine, bootstrap, css, django, htmx, javascript, python, sqlite
- Language: Python
- Homepage:
- Size: 43.4 MB
- Stars: 2
- Watchers: 2
- Forks: 0
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
Awesome Lists containing this project
README
# Simple Bookstore app
I made this web app in the last year at the college :school:.
It didn't had fancy JavaScript framework, just pure Django + little bit of jQuery :older_man:.
There is hype going around with HTMX library. So I decided to give it a try :cool:.
## Tech Stack
Backend: Python + Django :snake:
Database: SQLite :department_store:
Frontend: HTMX + Alpine.js :snowboarder:
## Run the application
### Clone the repo
```console
git clone https://github.com/uros-5/bookstore
cd bookstore
```### Setup virtual environment for python.
```console
python3 -m venv venv
source venv/bin/activate
```### Install dependencies
```console
pip3 install -r requirements.txt
```### Make migrations for database
```console
python3 manage.py makemigrations
python3 manage.py migrate
```### Fill database with data(users, authors, books, orders)
Populating database will be executed in 'django shell'.
```console
python3 manage.py shell
```
In shell paste this```python
from bookstore import db_work
```
It will fetch images and do all database related work.### Build frontend
```console
cd bookstore/ui
npm install
npm run build
cd ../..
```### Run server
```console
sh runserver.sh
```### Screenshots
![screenshot1](./bookstore/ui/src/media/images/screenshots/screenshot1.png)
![screenshot2](./bookstore/ui/src/media/images/screenshots/screenshot2.png)
![screenshot3](./bookstore/ui/src/media/images/screenshots/screenshot3.png)
![screenshot4](./bookstore/ui/src/media/images/screenshots/screenshot4.png)
![gif](./bookstore/ui/src/media/images/screenshots/htmx.gif)