Skip to content

Commit

Permalink
Merge pull request #10 from jacob-shuman/feat-svelte-5
Browse files Browse the repository at this point in the history
feat: upgrade to svelte 5
  • Loading branch information
jacob-shuman authored Sep 12, 2024
2 parents 4035580 + 94eb469 commit 46602e7
Show file tree
Hide file tree
Showing 11 changed files with 192 additions and 200 deletions.
34 changes: 20 additions & 14 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -75,7 +75,7 @@ I'm still looking into how rss aggregators generally handle auth for feeds and o

## :heavy_plus_sign: Add an article

**Requires Authentication**
:lock: **Requires Authentication**

You can add an article by providing the article's url in the body of a `POST` request:

Expand Down Expand Up @@ -111,11 +111,11 @@ You can add an article by providing the article's url in the body of a `POST` re
| 200 | `article added successfully` | `undefined` | `application/json` |
| 400 | `url is required` | `undefined` | `undefined` |
| 400 | `unable to extract metadata at {url}` | `undefined` | `undefined` |
| 401 | `not authorized"` | `undefined` | `undefined` |
| 401 | `not authorized` | `undefined` | `undefined` |

## :page_facing_up: Get a single `JSON` article

**Requires Authentication**
:lock: **Requires Authentication**

You can get a single `JSON` object representing an article by making a `GET` request to the `/articles/:id` route:

Expand All @@ -126,27 +126,27 @@ You can get a single `JSON` object representing an article by making a `GET` req
| Status | StatusText | Body | Content-Type |
| ------ | ----------------------------------------- | ----------- | ------------------ |
| 200 | `undefined` | `Article` | `application/json` |
| 401 | `not authorized"` | `undefined` | `undefined` |
| 401 | `not authorized` | `undefined` | `undefined` |
| 404 | `there is no article with an id of ":id"` | `undefined` | `undefined` |

## :clipboard: Get a `JSON` array of all articles

**Requires Authentication**
:lock: **Requires Authentication**

You can get a `JSON` array of articles by making a `GET` request to the `/articles` route:

`GET (http|https)://HOST:PORT/articles`

### Responses

| Status | StatusText | Body | Content-Type |
| ------ | ----------------- | ----------- | ------------------ |
| 200 | `undefined` | `Article[]` | `application/json` |
| 401 | `not authorized"` | `undefined` | `undefined` |
| Status | StatusText | Body | Content-Type |
| ------ | ---------------- | ----------- | ------------------ |
| 200 | `undefined` | `Article[]` | `application/json` |
| 401 | `not authorized` | `undefined` | `undefined` |

## :memo: Update an article

**Requires Authentication**
:lock: **Requires Authentication**

You can update an article based on it's id by making a `PATCH` request to the `/articles/:id/update` route:

Expand Down Expand Up @@ -175,12 +175,12 @@ You can update an article based on it's id by making a `PATCH` request to the `/
| Status | StatusText | Body | Content-Type |
| ------ | ------------------------------------ | ----------- | ------------ |
| 200 | `article :id deleted successfully` | `undefined` | `undefined` |
| 401 | `not authorized"` | `undefined` | `undefined` |
| 401 | `not authorized` | `undefined` | `undefined` |
| 404 | `there is no article with id of :id` | `undefined` | `undefined` |

## :wastebasket: Delete an article

**Requires Authentication**
:lock: **Requires Authentication**

You can delete an article based on it's id by making a `DELETE` request to the `/articles/:id/delete` route:

Expand All @@ -196,7 +196,7 @@ You can delete an article based on it's id by making a `DELETE` request to the `

## :wastebasket: Remove all articles

**Requires Authentication**
:lock: **Requires Authentication**

`DELETE (http|https)://HOST:PORT/articles/clear`

Expand All @@ -209,7 +209,7 @@ You can delete an article based on it's id by making a `DELETE` request to the `

## :wastebasket: Purge old articles

**Requires Authentication**
:lock: **Requires Authentication**

You can manually purge articles older than a certain threshhold using the `/articles/purge` route. Simply pass an `older_than` query parameter in the url with the following format:

Expand All @@ -220,6 +220,12 @@ m = months
y = years
<integer>h|d|m|y
Examples
30d = 30 days
4m = 4 months
2y = 2 years
```

> Please note the `older_than` parameter does **not** accept numbers with decimals.
Expand Down
8 changes: 4 additions & 4 deletions package.json
Original file line number Diff line number Diff line change
Expand Up @@ -21,7 +21,7 @@
"@iconify/svelte": "^4.0.2",
"@sveltejs/adapter-node": "^5.2.2",
"@sveltejs/kit": "^2.0.0",
"@sveltejs/vite-plugin-svelte": "^3.0.0",
"@sveltejs/vite-plugin-svelte": "4.0.0-next.7",
"@types/better-sqlite3": "^7.6.11",
"@types/eslint": "^9.6.0",
"@types/rss": "^0.0.32",
Expand All @@ -36,11 +36,11 @@
"jose": "^5.8.0",
"kysely": "^0.27.4",
"kysely-ctl": "^0.9.0",
"prettier": "^3.1.1",
"prettier-plugin-svelte": "^3.1.2",
"prettier": "^3.3.3",
"prettier-plugin-svelte": "^3.2.6",
"prettier-plugin-tailwindcss": "^0.6.5",
"radash": "^12.1.0",
"svelte": "^4.2.7",
"svelte": "5.0.0-next.244",
"svelte-check": "^3.6.0",
"tailwind-merge": "^2.5.2",
"tailwindcss": "^3.4.9",
Expand Down
Loading

0 comments on commit 46602e7

Please sign in to comment.