-
Steven authored
Security improvements: - Add rehype-sanitize for XSS protection in markdown content - Remove DOMPurify and deprecated __html code block feature - Extract sanitize schema to constants with comprehensive documentation Maintainability improvements: - Extract SANITIZE_SCHEMA to constants.ts for better organization - Create utils.ts with shared code extraction utilities - Refactor CodeBlock and MermaidBlock to use shared utilities - Rename PreProps to CodeBlockProps for clarity - Reduce code duplication across components Dependency cleanup: - Remove explicit katex dependency (now transitive via rehype-katex) - Remove @matejmazur/react-katex (unused) - Remove dompurify (replaced by rehype-sanitize) - Update vite config to remove katex-vendor chunk Changes: 7 files changed, 84 insertions(+), 100 deletions(-)
🤖 Generated with [Claude Code](https://claude.com/claude-code) Co-Authored-By:Claude <noreply@anthropic.com>
4668c471
| Name |
Last commit
|
Last update |
|---|---|---|
| .github | ||
| cmd/memos | ||
| internal | ||
| plugin | ||
| proto | ||
| scripts | ||
| server | ||
| store | ||
| web | ||
| .dockerignore | ||
| .gitignore | ||
| .golangci.yaml | ||
| CLAUDE.md | ||
| CODEOWNERS | ||
| LICENSE | ||
| README.md | ||
| SECURITY.md | ||
| go.mod | ||
| go.sum |