|
1 |
| -# 🔗 Real-Time Local Sharing App |
2 | 1 |
|
3 |
| -[中文版](./documents/README-CN.md) |
| 2 | +# LetShare – Effortless File & Text Sharing Across Devices 🚀 |
4 | 3 |
|
5 |
| - |
6 |
| - |
7 |
| - |
8 |
| - |
9 |
| - |
10 | 4 |
|
| 5 | +[](LICENSE) |
| 6 | +[](https://letshare.fun) |
| 7 | +[](https://vitejs.dev) |
| 8 | +[](https://mui.com) |
| 9 | +[](https://capacitorjs.com) |
11 | 10 |
|
12 |
| -A lightweight real-time collaboration and file-sharing app designed for seamless communication within the same local network. Built with **React**, **WebRTC**, and **WebSocket**, it supports sharing **files**, **text**, and **clipboard content** with nearby users. |
| 11 | +[中文版](./documents/README-CN.md) |
13 | 12 |
|
14 |
| ---- |
| 13 | +LetShare is a blazing-fast, lightweight tool for sharing files, text, images, and clipboard content between devices — no login, no cloud, no nonsense. |
15 | 14 |
|
16 |
| -## ✨ Features |
| 15 | +Share anywhere. Phone to laptop. Android to browser. Clipboard to clipboard. |
17 | 16 |
|
18 |
| -- 📁 **File Transfer**: Send files peer-to-peer without uploading to a server. |
19 |
| -- 📝 **Text & Clipboard Sharing**: Share custom text or clipboard content instantly. |
20 |
| -- 🌐 **LAN Peer Discovery**: Automatically find other users connected to the same Wi-Fi. |
21 |
| -- 🔄 **Reconnection Mechanism**: Auto-reconnect to disconnected users. |
22 |
| -- 🔥 **Drag & Drop Upload**: Easily drag files into the app window to share. |
23 |
| -- 🚫 **Abort Transfer**: Cancel file sending in real-time. |
24 |
| -- 🧊 **Material UI Components**: Clean, responsive interface using MUI. |
| 17 | + |
25 | 18 |
|
26 | 19 | ---
|
27 | 20 |
|
28 |
| -## 📦 Technologies Used |
| 21 | +## ✨ Features |
29 | 22 |
|
30 |
| -- **React (TypeScript)** |
31 |
| -- **Material UI (MUI)** |
32 |
| -- **WebSocket** for signaling and peer discovery |
33 |
| -- **WebRTC** for direct peer-to-peer data transfer |
34 |
| -- **Clipboard API** for sharing copied content |
35 |
| -- **Custom Utility Kit** for delay, ID management, etc. |
| 23 | +- 📡 **Peer-to-peer** local sharing via WebRTC |
| 24 | +- 💻 **Cross-platform** support: browser & native Android app |
| 25 | +- 🔒 **Private & offline-first** – no cloud upload, all local |
| 26 | +- 🧾 **Text, file, image, clipboard** – share anything instantly |
| 27 | +- 🌐 **Multi-language UI** (English / 中文 / Bahasa Melayu / Indonesia) |
| 28 | +- 🖼️ **QR-code based pairing** – scan & connect |
| 29 | +- 🎨 **Clean Material UI**, responsive design |
| 30 | +- ⚙️ **Built with Vite**, React, MobX, Capacitor |
36 | 31 |
|
37 | 32 | ---
|
38 | 33 |
|
39 |
| -## 🚀 Getting Started |
| 34 | +## 🧪 Tech Stack |
40 | 35 |
|
41 |
| -### Prerequisites |
| 36 | +- React + Vite + TypeScript |
| 37 | +- MUI 5 (Material Design UI) |
| 38 | +- WebRTC + Ably for real-time messaging |
| 39 | +- MobX for state management |
| 40 | +- Capacitor for Android native support |
| 41 | +- i18next + detector for language handling |
| 42 | +- JSZip, Clipboard API, react-qrcode-logo |
42 | 43 |
|
43 |
| -- Node.js (v16+ recommended) |
44 |
| -- Yarn or npm |
| 44 | +--- |
45 | 45 |
|
46 |
| -### Installation |
| 46 | +## 🔧 Scripts (via Yarn) |
47 | 47 |
|
48 | 48 | ```bash
|
49 |
| -# Install dependencies |
50 |
| -npm install |
51 |
| - |
52 |
| -# Or |
53 |
| -yarn install |
54 |
| -``` |
55 |
| - |
56 |
| -### Start the Development Server |
57 |
| - |
58 |
| -```bash |
59 |
| -npm run dev |
60 |
| - |
61 |
| -# Or |
62 |
| -yarn dev |
| 49 | +yarn dev # Run development server |
| 50 | +yarn build # Build production web app |
| 51 | +yarn app # Build & sync Android app (via Capacitor) |
| 52 | +yarn app-start # Open Android Studio |
| 53 | +yarn preview # Preview built site |
63 | 54 | ```
|
64 | 55 |
|
65 | 56 | ---
|
66 | 57 |
|
67 |
| -## 🌍 Usage |
68 |
| - |
69 |
| -1. Open the app in two different tabs or devices connected to the same network. |
70 |
| -2. Click **"Search Nearby Users"** to discover peers. |
71 |
| -3. Choose a file, input some text, or select clipboard mode. |
72 |
| -4. Click a discovered user to send your content. |
73 |
| -5. A dialog will appear on the receiver's screen to accept or decline. |
| 58 | +## 🌍 Try It Now |
74 | 59 |
|
75 |
| ---- |
| 60 | +Visit the live app at: |
| 61 | +👉 **https://letshare.fun** |
76 | 62 |
|
77 |
| -## 📁 File Transfer Notes |
78 |
| - |
79 |
| -- File transfer uses WebRTC **DataChannels**. |
80 |
| -- Signaling is handled via a lightweight **WebSocket server**. |
81 |
| -- Large files are chunked and transferred with progress feedback. |
| 63 | +No install. No login. Works on any modern browser. |
82 | 64 |
|
83 | 65 | ---
|
84 | 66 |
|
85 |
| -## 🧪 Developer Notes |
86 |
| - |
87 |
| -- `colabLib.ts` handles all WebRTC + signaling logic. |
88 |
| -- The app automatically cleans up disconnected users. |
89 |
| -- Auto-reconnect checks run every ~3.5 seconds. |
90 |
| -- Clipboard support may vary depending on browser permissions. |
| 67 | +## 📲 Android App |
91 | 68 |
|
92 |
| ---- |
93 |
| - |
94 |
| -## ⚙️ Configuration |
| 69 | +Build native Android app: |
95 | 70 |
|
96 |
| -The signaling server URL is defined in the code: |
97 |
| -```ts |
98 |
| -const url = "wss://your-server-url"; |
| 71 | +```bash |
| 72 | +yarn app-create |
| 73 | +yarn app |
| 74 | +yarn app-start |
99 | 75 | ```
|
100 | 76 |
|
101 |
| -You can switch to a local server for development: |
102 |
| -```ts |
103 |
| -const url = "ws://localhost:9000"; |
104 |
| -``` |
| 77 | +Requires Android Studio & Capacitor CLI. |
105 | 78 |
|
106 | 79 | ---
|
107 | 80 |
|
108 |
| -## 📷 Screenshots |
| 81 | +## 📄 License |
109 | 82 |
|
110 |
| -> _Add your screenshots here to visualize the app's UX_ |
| 83 | +MIT © 2025 Onion |
111 | 84 |
|
112 | 85 | ---
|
113 | 86 |
|
114 |
| -## 📜 License |
| 87 | +## ⭐️ Contribute |
| 88 | + |
| 89 | +Found it useful? Give us a ⭐ at |
| 90 | +https://github.com/LiWeny16/LetShare |
115 | 91 |
|
116 |
| -MIT License © 2025 |
| 92 | +Pull requests welcome. Let’s build frictionless sharing together! |
117 | 93 |
|
0 commit comments