This is a Next.js application for collaborative document editing, built with Liveblocks, Clerk, and Sentry.
app/
: Core application logic (Next.js App Router).(auth)/
: Authentication routes (sign-in, sign-up) using Clerk.(root)/
: Main application routes (document display, editing).api/
: API routes (Liveblocks auth, Sentry).
components/
: Reusable UI components.editor/
: Document editor components.ui/
: Generic UI components.
lib/
: Utility functions and libraries.actions/
: Server-side actions (rooms, users).
public/
: Static assets (icons, images).styles/
: CSS files and themes.- Configuration Files:
next.config.mjs
,tailwind.config.ts
,liveblocks.config.ts
, Sentry configs, etc.
- User authentication (sign-in, sign-up).
- Real-time collaborative document editing.
- Document creation, sharing, and deletion.
- Notifications.
- Comments.
The following environment variables are used in this project. Please ensure they are set up correctly in your environment.
CI
: Used innext.config.mjs
to control the verbosity of Sentry's build logs (e.g.,silent: !process.env.CI
). Set totrue
in CI environments to reduce log noise.SENTRY_DSN
: Your Sentry Data Source Name for error tracking.NODE_ENV
: Specifies the environment (e.g.,development
,production
).
Note: This list might be incomplete. You may need to configure additional environment variables for services like Clerk and Liveblocks. Refer to their respective documentation for more details. Specifically, you will likely need:
NEXT_PUBLIC_CLERK_PUBLISHABLE_KEY
CLERK_SECRET_KEY
NEXT_PUBLIC_LIVEBLOCKS_PUBLIC_KEY
LIVEBLOCKS_SECRET_KEY
- Clone the repository:
git clone <repository-url> cd <repository-directory>
- Install dependencies:
npm install # or yarn install
- Set up environment variables:
Create a
.env.local
file in the root of the project and add the necessary environment variables.CI= SENTRY_DSN= NODE_ENV=development NEXT_PUBLIC_CLERK_PUBLISHABLE_KEY=your_clerk_publishable_key CLERK_SECRET_KEY=your_clerk_secret_key NEXT_PUBLIC_LIVEBLOCKS_PUBLIC_KEY=your_liveblocks_public_key LIVEBLOCKS_SECRET_KEY=your_liveblocks_secret_key
- Run database migrations (if applicable): (Add details here if database migrations are needed)
- Start the development server:
npm run dev # or yarn dev
- Open your browser and navigate to
http://localhost:3000
.
Contributions are welcome! Please follow these steps:
- Fork the repository.
- Create a new branch (
git checkout -b feature/your-feature-name
). - Make your changes.
- Commit your changes (
git commit -m 'Add some feature'
). - Push to the branch (
git push origin feature/your-feature-name
). - Open a Pull Request.
(Add license information here if a license file exists or specify the license, e.g., MIT License.)