Skip to content

Commit

Permalink
update readme
Browse files Browse the repository at this point in the history
  • Loading branch information
1ntEgr8 committed Apr 28, 2021
1 parent 767aee2 commit 4e3324c
Show file tree
Hide file tree
Showing 3 changed files with 10 additions and 11 deletions.
1 change: 1 addition & 0 deletions .gitignore
Original file line number Diff line number Diff line change
@@ -1 +1,2 @@
*.db
arss
8 changes: 4 additions & 4 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -14,14 +14,14 @@ I wanted a very minimal RSS reader that **wasn't** feature packed, but could be
git clone https://github.com/1ntEgr8/arss
```

- Install by running
- Build the client and server
```
make install path/to/installation/directory
npm --prefix client run build && go build arss
```

Example:
- Run the program
```
make install /usr/local/bin
./arss
```

## Usage
Expand Down
12 changes: 5 additions & 7 deletions client/src/App.svelte
Original file line number Diff line number Diff line change
Expand Up @@ -12,13 +12,11 @@
import Sidebar from "./components/Sidebar.svelte";
import Feed from "./components/Feed.svelte";
const PORT = 8080;
let sources = [];
let selected = -1;
async function fetchSources() {
const res = await fetch(`http://localhost:${PORT}/sources`)
const res = await fetch(`/sources`)
const data = await res.json();
sources = data;
if (data?.length > 0) {
Expand All @@ -28,7 +26,7 @@
}
async function fetchFeed(id) {
const res = await fetch(`http://localhost:${PORT}/feed/${id}`);
const res = await fetch(`/feed/${id}`);
const data = await res.json();
if (res.ok) {
return data["items"];
Expand All @@ -46,7 +44,7 @@
sources[idx].name = name;
sources[idx].url = url;
const res = await fetch(`http://localhost:${PORT}/sources/edit/${sourceId}`, {
const res = await fetch(`/sources/edit/${sourceId}`, {
method: "POST",
body: JSON.stringify({ name, url })
});
Expand All @@ -62,7 +60,7 @@
selected = selected - 1;
}
const res = await fetch(`http://localhost:${PORT}/sources/del/${sourceId}`, {
const res = await fetch(`/sources/del/${sourceId}`, {
method: "POST"
});
Expand All @@ -73,7 +71,7 @@
}
async function addSource(name, url) {
const res = await fetch(`http://localhost:${PORT}/sources/add`, {
const res = await fetch(`/sources/add`, {
method: "POST",
body: JSON.stringify({name, url})
});
Expand Down

0 comments on commit 4e3324c

Please sign in to comment.