import { NextResponse } from 'next/server' import { promises as fs } from 'fs' import { auth } from '@/auth' import { prisma } from '@/lib/prisma' import JSZip from 'jszip' import DOMPurify from 'isomorphic-dompurify' import type { BrainstormIdea, Note } from '@prisma/client' function htmlToMarkdown(html: string): string { if (!html) return '' let md = html .replace(/
(.*?)<\/p>/gi, '$1\n\n') .replace(/
Explore your entire workspace offline. Use the sidebar to search and select your notes and canvases.
Meta description