# LAN Chat VS Code Extension
LAN-only chat inside VS Code. Uses a local WebSocket server (Node `ws`) and a React-based sidebar webview.
## Requirements
- Node.js 18+
- VS Code 1.85+
## Install & Run (Dev)
```bash
# 1) Install root & webview deps
npm ci
# 2) Build webview and extension
npm run build
# 3) Launch the Extension Host (F5)
# Or: Run from VS Code: Run and Debug -> Run Extension
Usage
On the host machine (the one running the server):
Open Command Palette → LAN Chat: Start Server → choose a port (default 8787).
You’ll see a message with your local IPs. Pick the one on your LAN (e.g., 192.168.1.23).
On each client machine:
Open the sidebar (Activity Bar → LAN Chat / or Command Palette: LAN Chat: Open Sidebar).
Enter Your name, Server IP, Port, then click Connect.
Start chatting. Your messages show on the right; others on the left.
Stop the Server
Command Palette → LAN Chat: Stop Server.
Notes
No internet required. All traffic stays on the LAN.
No database. Messages are ephemeral (in-memory only). Close the panel → history is gone.
If you need persistence, you can add a local DB, but this keeps it lightweight.
Packaging
# If you want to package as a .vsix (optional):
# npm i -g @vscode/vsce
# vsce package