Skip to content

feat: rewrite with hono and alpine - #143

Merged
ArnabXD merged 19 commits into
mainfrom
feat/hono-alpine
Oct 16, 2026
Merged

ArnabXD merged 19 commits into
mainfrom
feat/hono-alpine

Conversation

@ArnabXD

@ArnabXD ArnabXD commented Oct 16, 2026

Copy link
Copy Markdown
Owner

Rewrites the index from Next.js 12 to Hono + Alpine.js. One codebase runs on Cloudflare Workers, Vercel and any Node host, with no client bundle.

Features

  • Folder browsing with breadcrumbs, back/forward and deep links
  • Instant filter in the current folder, Enter searches the whole Dropbox
  • Sort by name, size or date with natural ordering
  • Preview images, video, audio, Markdown and text files, step through with ← →
  • Folder README.md rendered below the listing
  • Permanent share links (/api/dl/* redirects to a fresh temporary link)
  • Optional HTTP Basic auth (AUTH_USER / AUTH_PASS)
  • Empty, error and loading states; light/dark theme; mobile layout; Lucide icons

Under the hood

  • Dropbox API via plain fetch (no SDK); errors keep their real HTTP status
  • Access token cached per instance with a single in-flight refresh, shared through the Cache API where available
  • Listing/search/preview responses cached for 60s via hono/cache (no-op on Node)
  • Markdown sanitized with DOMPurify; raw file content served as text/plain with nosniff
  • Tooling: Vite+ (vp dev, vp check, vp build), pnpm, CI runs vp check

Deploy

  • Cloudflare Workers: Deploy to Cloudflare button (wrangler.toml, secrets from .env.example)
  • Vercel: zero-config Hono
  • Node: pnpm vp build && pnpm start

Breaking changes

  • NEXT_PUBLIC_TITLE is now TITLE
  • .env.sample is now .env.example
  • Render config removed (any Node host still works)
  • Requires Node 22.18+ and pnpm

Closes #24, closes #89, closes #126, closes #129

@ArnabXD
ArnabXD merged commit f73af47 into main Oct 16, 2026
2 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Files Sorting Trouble deploying Add Basic Authentication Support Add Markdown render support

1 participant