upload to github
This commit is contained in:
commit
92cc81e813
51 changed files with 8041 additions and 0 deletions
55
README.md
Normal file
55
README.md
Normal file
|
|
@ -0,0 +1,55 @@
|
|||
# E-inn
|
||||
|
||||
E-inn is a basic EPUB reader supporting remote API imports and local file uploads. Books are stored in IndexedDB; settings and reading progress are retained via localStorage. Built as a single-page application with Vue.js, Vue Router, and epub.js for rendering. No accounts, sync, or advanced features, serves static assets. Minimal UI, lightweight, customizable interface.
|
||||
|
||||
## Running
|
||||
|
||||
Run development server with:
|
||||
```
|
||||
docker-compose up dev
|
||||
```
|
||||
|
||||
Run clean build with:
|
||||
```
|
||||
docker-compose up build
|
||||
```
|
||||
|
||||
### API reasoning:
|
||||
|
||||
If you have a userbase, you can use a centralized database for your content and the e-inn-reader as client. You only need to set some environment variables in the .env and build this project
|
||||
|
||||
```
|
||||
VITE_REMOTE_API='true'
|
||||
VITE_API_URL=http://localhost/api # your server
|
||||
```
|
||||
|
||||
# Api server requirements
|
||||
|
||||
### `GET` `/api/epub-library`
|
||||
Returns: `JSON`
|
||||
```json
|
||||
{
|
||||
"epubs": [
|
||||
{
|
||||
"id": "id",
|
||||
"filename": "book-title.epub",
|
||||
"path": "/storage/path",
|
||||
"size": 4521120
|
||||
}
|
||||
],
|
||||
"total": 15
|
||||
}
|
||||
```
|
||||
|
||||
#### `GET` `/api/epub/{id}/{filename}`
|
||||
Parameters:
|
||||
- `id`: `string`
|
||||
- `filename`: `string`
|
||||
|
||||
|
||||
## Return: Binary EPUB file with Content-Type: application/epub+zip
|
||||
```
|
||||
OPTIONS /api/epub-library
|
||||
OPTIONS /api/epub/{id}/{filename}
|
||||
Returns: Empty response with CORS headers
|
||||
```
|
||||
Loading…
Add table
Add a link
Reference in a new issue