be4d43105e
Node.js/Express backend + vanilla JS frontend. Features: real-time collaborative whiteboard (SSE), multi-page support, LaTeX formulas, shapes/connectors, coordinate systems, number lines, compass, zoom/pan, Catmull-Rom pencil smoothing, ruler/protractor with rotation & resize controls, minimap navigation overlay, auto-measurements, multi-page thumbnails sidebar, PNG export, page templates. Student/teacher workflows: classes, assignments, library, dashboard. Mobile responsive. SQLite (better-sqlite3). Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
14 lines
482 B
JavaScript
14 lines
482 B
JavaScript
const router = require('express').Router();
|
|
const { authMiddleware } = require('../middleware/auth');
|
|
const ctrl = require('../controllers/notificationController');
|
|
|
|
// SSE stream — auth done inside handler via ?token param (EventSource can't set headers)
|
|
router.get('/stream', ctrl.stream);
|
|
|
|
router.use(authMiddleware);
|
|
router.get('/', ctrl.list);
|
|
router.post('/read-all', ctrl.markAllRead);
|
|
router.patch('/:id/read', ctrl.markRead);
|
|
|
|
module.exports = router;
|