Skip to content

AayushBharti/Next-Venture

VentureDen

A modern, full-stack monorepo built with Next.js App Router, Sanity CMS, Shadcn UI, and TurboRepo.

Features

Monorepo Structure

  • Apps: web (Next.js frontend) and studio (Sanity Studio)
  • Shared packages: UI components, TypeScript config, environment utilities, logger
  • Turborepo for build orchestration and caching

Frontend (Web)

  • Next.js App Router with TypeScript
  • Shadcn UI components with Tailwind CSS
  • Server Components and Server Actions
  • SEO optimization with metadata
  • Blog system with rich text editor
  • Table of contents generation
  • Responsive layouts

Content Management (Studio)

  • Sanity Studio v5
  • Custom document types (Blog, FAQ, Pages)
  • Visual editing integration
  • Structured content with schemas
  • Live preview capabilities
  • Asset management

Getting Started

1. Install dependencies

pnpm install

2. Run Studio and Next.js app locally

pnpm run dev

3. Open the app and sign in to the Studio

Open the Next.js app running locally in your browser on http://localhost:3000.

Open the Studio running locally in your browser on http://localhost:3333. You should now see a screen prompting you to log in to the Studio. Use the same service (Google, GitHub, or email) that you used when you logged in to the CLI.

Adding content with Sanity

1. Publish your first document

The project comes pre-defined with a schema containing Author, Blog, BlogIndex, FAQ, Footer, HomePage, Navbar, Page, and Settings document types.

From the Studio, click "+ Create" and select the Blog document type. Go ahead and create and publish the document.

Your content should now appear in your Next.js app (http://localhost:3000) as well as in the Studio on the "Presentation" Tab

2. Sample Content

Sample content can be imported after setup. This data includes example blog posts, authors, and other content types to help you get started quickly (see next step).

3. Seed data using script

To add sample data programmatically, run the following command:

cd apps/studio
npx sanity dataset import ./seed-data.tar.gz production --replace

This command imports seed content into your Sanity dataset.

4. Extending the Sanity schema

The schemas for all document types are defined in the studio/schemaTypes/documents directory. You can add more document types to the schema to suit your needs.

Deploying your application and inviting editors

1. Deploy Sanity Studio

Your Next.js frontend (/web) and Sanity Studio (/studio) are still only running on your local computer. It's time to deploy and get it into the hands of other content editors.

The project includes a GitHub Actions workflow deploy-sanity.yml that automatically deploys your Sanity Studio whenever changes are pushed to the studio directory.

Note: To use the GitHub Actions workflow, make sure to configure the following secrets in your repository settings:

  • SANITY_DEPLOY_TOKEN
  • SANITY_STUDIO_PROJECT_ID
  • SANITY_STUDIO_DATASET
  • SANITY_STUDIO_TITLE
  • SANITY_STUDIO_PRESENTATION_URL
  • SANITY_STUDIO_PRODUCTION_HOSTNAME

Set SANITY_STUDIO_PRODUCTION_HOSTNAME to whatever you want your deployed Sanity Studio hostname to be. Eg. for SANITY_STUDIO_PRODUCTION_HOSTNAME=venture-den you'll get a studio URL of https://venture-den.sanity.studio.

Set SANITY_STUDIO_PRESENTATION_URL to your web app front-end URL (from the Vercel deployment). This URL is required for production deployments and should be:

  • Set in your GitHub repository secrets for CI/CD deployments
  • Set in your local environment if deploying manually with npx sanity deploy
  • Not needed for local development, where preview will automatically use http://localhost:3000

You can then manually deploy from your Studio directory (/studio) using:

npx sanity deploy

Note: To use the live preview feature, your browser needs to enable third party cookies.

2. Deploy Next.js app to Vercel

You have the freedom to deploy your Next.js app to your hosting provider of choice. With Vercel and GitHub being a popular choice, we'll cover the basics of that approach.

  1. Create a GitHub repository from this project. Learn more.
  2. Create a new Vercel project and connect it to your Github repository.
  3. Set the Root Directory to your Next.js app (/apps/web).
  4. Configure your Environment Variables.

3. Configure CORS Origins

Your production URLs must be added to your Sanity project's CORS origins, otherwise the frontend will be blocked from fetching content.

  1. Go to Sanity Manage, select your project, and navigate to API > CORS origins.
  2. Add the following origins:
    • Your production URL (e.g. https://your-app.vercel.app)
    • Your custom domain if applicable (e.g. https://yourdomain.com)
    • http://localhost:3000 (for local development — added by default)
  3. Enable Allow credentials for each origin that needs authenticated requests (e.g. live preview, visual editing).

Note: Vercel preview deployments use unique URLs per commit. If you need CORS access on preview deployments, add a wildcard origin like https://*-your-project.vercel.app or add specific preview URLs as needed.

4. Invite a collaborator

Now that you've deployed your Next.js application and Sanity Studio, you can optionally invite a collaborator to your Studio. Open up Manage, select your project and click "Invite project members"

They will be able to access the deployed Studio, where you can collaborate together on creating content.

About

A platform designed for early-stage entrepreneurs to pitch, browse, and engage with startup ideas. It’s built to impress both users and investors with blazing speed, compelling visuals, and a modern tech stack.

Topics

Resources

License

Code of conduct

Contributing

Security policy

Stars

Watchers

Forks

Releases

No releases published

Packages

 
 
 

Contributors

Languages