readingroom 0.3.0 → 0.4.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/README.md +32 -6
- package/dist/assets/index-BRMmjGIp.js +190 -0
- package/dist/assets/index-C2oluWMZ.css +2 -0
- package/dist/index.html +2 -2
- package/package.json +1 -1
- package/src/server.js +386 -12
- package/src/tunnel.js +294 -0
- package/dist/assets/index-BFXOIu5r.css +0 -2
- package/dist/assets/index-BWX1yNrT.js +0 -190
package/README.md
CHANGED
|
@@ -8,20 +8,23 @@ One command, and every `.md`, `.txt`, image, and PDF file in your project is bro
|
|
|
8
8
|
npx readingroom
|
|
9
9
|
```
|
|
10
10
|
|
|
11
|
-
Codebases are drowning in documentation: READMEs, design docs, agent instructions, plans, notes, changelogs. Editors are great at code, but docs get buried in nested folders and drowned out by source files. `readingroom` shows _only_ the files you care about - a folder tree
|
|
11
|
+
Codebases are drowning in documentation: READMEs, design docs, agent instructions, plans, notes, changelogs. Editors are great at code, but docs get buried in nested folders and drowned out by source files. `readingroom` shows _only_ the files you care about - a folder tree on the left, preview on the right.
|
|
12
12
|
|
|
13
13
|
## What you get
|
|
14
14
|
|
|
15
15
|
- **Sidebar tree** of every `.md`, `.txt`, image, and PDF file, with document counts per folder.
|
|
16
|
-
- **File-type filter** under the search box
|
|
16
|
+
- **File-type filter** - chips under the search box narrow the list to Markdown, text, images, or PDF (only types your project actually has appear), each with a live count.
|
|
17
17
|
- **Rendered markdown** - GitHub-flavored (tables, task lists), syntax-highlighted code blocks, collapsed YAML frontmatter; `.txt` files shown as plain text
|
|
18
18
|
- **Images** - `png`, `jpg`, `jpeg`, `webp`, `gif`, `avif`, and `svg` render right in the viewer
|
|
19
19
|
- **PDFs** - rendered by your browser's built-in viewer, with an "Open in system viewer" fallback for browsers that can't display PDFs inline
|
|
20
|
-
- **
|
|
20
|
+
- **Download** - a download button next to every open file saves it to your computer; if you're viewing an older version from the History panel, you get that exact version
|
|
21
|
+
- **File details & history** - a side panel shows the essentials at a glance (size, word count, reading time, who last edited the file), plus a History tab listing every saved change - click one to view the file as it was back then
|
|
22
|
+
- **Filter by name** - press `/` and start typing
|
|
21
23
|
- **Live reload** - files created, edited, or deleted by you (or your AI agents) appear instantly
|
|
22
|
-
- **Deep-linkable URLs** - `/view/docs/plan.md` works on reload
|
|
24
|
+
- **Deep-linkable URLs** - `/view/docs/plan.md` works on reload
|
|
23
25
|
- **Relative links work** - links between markdown files open in the viewer; images referenced by docs are served
|
|
24
|
-
- **Dark + light mode**
|
|
26
|
+
- **Dark + light mode** - follows your OS setting, or pick your own
|
|
27
|
+
- **Read on your phone** - scan a QR code and keep reading on your phone, on the same Wi-Fi or from anywhere
|
|
25
28
|
|
|
26
29
|
## What it shows (and skips)
|
|
27
30
|
|
|
@@ -34,6 +37,18 @@ It stays out of your way:
|
|
|
34
37
|
- Symlinks are not followed; there is no file size limit - if your browser can handle it, it gets listed
|
|
35
38
|
- It is strictly **read-only** - readingroom never writes to your project
|
|
36
39
|
|
|
40
|
+
## Demo
|
|
41
|
+
|
|
42
|
+
[Watch the demo on YouTube](https://youtu.be/mOOgsZkM8pA)
|
|
43
|
+
|
|
44
|
+
## File history and downloads
|
|
45
|
+
|
|
46
|
+

|
|
47
|
+
|
|
48
|
+
Open a file and the panel on the right tells you about it: how big it is, how long it takes to read, and - if your project uses git - who last touched it. The **History** tab goes further back in time: every saved change is listed, and clicking one shows you the file exactly as it was at that point.
|
|
49
|
+
|
|
50
|
+
The download button next to the file name at the top always saves what you're looking at - open the current file and you get the current version, open a version from History and you get that one.
|
|
51
|
+
|
|
37
52
|
## CLI
|
|
38
53
|
|
|
39
54
|
```
|
|
@@ -47,7 +62,18 @@ readingroom [options]
|
|
|
47
62
|
-v, --version Show version
|
|
48
63
|
```
|
|
49
64
|
|
|
50
|
-
|
|
65
|
+
By default the server is visible only on your own machine (`127.0.0.1`) - the phone sharing described below is strictly opt-in. The server also validates the `Host` header (blocking DNS-rebinding attacks) and refuses any path that resolves outside the served directory.
|
|
66
|
+
|
|
67
|
+
## Read on your phone
|
|
68
|
+
|
|
69
|
+

|
|
70
|
+
|
|
71
|
+
Click the phone icon in the sidebar, then choose how your phone will connect:
|
|
72
|
+
|
|
73
|
+
- **Same Wi-Fi** - the fastest option when your phone and computer are on the same network. Scan the QR code and you're reading. Nothing leaves your network.
|
|
74
|
+
- **Any network** - for mobile data, a different Wi-Fi, or reading while away. "Open from anywhere" creates a private `trycloudflare.com` address that works from any network. The first time, a small helper tool from Cloudflare downloads automatically - there is nothing to install and no account to sign up for.
|
|
75
|
+
|
|
76
|
+
Both options are protected by a one-time access code built into the QR link, so only you get in. The code changes every time readingroom starts, and sharing stops as soon as you close the dialog or quit. The "any network" option relies on Cloudflare's free tunnel service - great for reading on the go, but best-effort rather than a permanent public link.
|
|
51
77
|
|
|
52
78
|
## Global Install (optional)
|
|
53
79
|
|