Skip to content

add SanityPress #945

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Open
wants to merge 1 commit into
base: main
Choose a base branch
from
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
5,828 changes: 5,828 additions & 0 deletions package-lock.json

Large diffs are not rendered by default.

4 changes: 4 additions & 0 deletions starter/sanitypress/.eslintrc.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,4 @@
{
"root": true,
"extends": "next/core-web-vitals"
}
42 changes: 42 additions & 0 deletions starter/sanitypress/.gitignore
Original file line number Diff line number Diff line change
@@ -0,0 +1,42 @@
# See https://help.github.com/articles/ignoring-files/ for more about ignoring files.

# Dependencies
/node_modules
/.pnp
.pnp.js

# Testing
/coverage

# Next.js
/.next/
/out/
next-env.d.ts

# Production
build
dist

# Misc
.DS_Store
*.pem

# Debug
npm-debug.log*
yarn-debug.log*
yarn-error.log*

# Local ENV files
.env.local
.env.development.local
.env.test.local
.env.production.local

# Vercel
.vercel

# Turborepo
.turbo

# typescript
*.tsbuildinfo
47 changes: 47 additions & 0 deletions starter/sanitypress/README.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,47 @@
---
name: SanityPress
slug: sanitypress
description: A fully customizable Next.js and Sanity starter template with Tailwind CSS and pre-built schema for rapid website development.
framework: Next.js
useCase: Starter, Blog, SaaS
css: Tailwind
githubUrl: https://github.com/nuotsu/sanitypress
demoUrl: https://sanitypress.dev
deployUrl: https://vercel.com/new/clone?repository-url=https%3A%2F%2Fgithub.com%2Fnuotsu%2Fsanitypress&env=NEXT_PUBLIC_BASE_URL,NEXT_PUBLIC_SANITY_PROJECT_ID,NEXT_PUBLIC_SANITY_DATASET,NEXT_PUBLIC_SANITY_TOKEN&envDescription=Values%20needed%20to%20connect%20a%20Sanity%20CMS&envLink=https%3A%2F%2Fsanitypress.dev%2Fdocs%2Fgetting-started&demo-title=SanityPress&demo-description=Official%20website%20and%20blog%20for%20SanityPress%2C%20built%20with%20SanityPress&demo-url=https%3A%2F%2Fsanitypress.dev&demo-image=https%3A%2F%2Fcdn.sanity.io%2Fimages%2Felyfelq1%2Fproduction%2F7fb61a2b110f509582f0f43cb1e397f8fa9e5c07-2814x1798.png%3Fw%3D1600
relatedTemplates:
- sanity-visual-editing-demo
- blog-nextjs-sanity
- blog-next-sanity
---

# SanityPress

A fully customizable Next.js and Sanity starter template with Tailwind CSS and pre-built schema for rapid website development.

[![Deploy with Vercel](https://vercel.com/button)](https://vercel.com/new/clone?repository-url=https%3A%2F%2Fgithub.com%2Fnuotsu%2Fsanitypress&env=NEXT_PUBLIC_BASE_URL,NEXT_PUBLIC_SANITY_PROJECT_ID,NEXT_PUBLIC_SANITY_DATASET,NEXT_PUBLIC_SANITY_TOKEN&envDescription=Values%20needed%20to%20connect%20a%20Sanity%20CMS&envLink=https%3A%2F%2Fsanitypress.dev%2Fdocs%2Fgetting-started&demo-title=SanityPress&demo-description=Official%20website%20and%20blog%20for%20SanityPress%2C%20built%20with%20SanityPress&demo-url=https%3A%2F%2Fsanitypress.dev&demo-image=https%3A%2F%2Fcdn.sanity.io%2Fimages%2Felyfelq1%2Fproduction%2F7fb61a2b110f509582f0f43cb1e397f8fa9e5c07-2814x1798.png%3Fw%3D1600)

Visit [here](https://sanitypress.dev/studio-screenshots) for more Studio screenshots.

- [x] 🖋️ Published on [Sanity.io](https://www.sanity.io/templates/sanitypress)
- [x] ⚡ [Perfect Lighthouse scores](https://pagespeed.web.dev/analysis?url=https%3A%2F%2Fsanitypress.dev%2F) on desktop and 99/100 on mobile.
- [x] 🚀 Checkout the [demo site](https://sanitypress.dev), [documentation](https://sanitypress.dev/docs) and [blog](https://sanitypress.dev/blog).

## Key Features

- [x] ✨ Modern Frontend Development with Next.js (App Router, RSC, Typescript) and Tailwind CSS.
- [x] 📕 [Pre-configured Sanity schema](/sanity/schemas/index.ts) for rapid content structuring.
- [x] 📘 [Pre-built frontend components](/next/src/ui/) for rapid website development.
- [x] ✏️ [Visual editing](https://sanitypress.dev/blog/visual-editing) right inside the Embedded Sanity Studio.
- [x] 📜 Auto-generated Table of Contents component based on headings.
- [x] ⌨️ Auto-generated [sitemap.xml](/next/src/app/sitemap.ts) and [blog rss.xml](/next/src/app/blog/rss.xml/route.ts).

## Getting Started

Directions are also found on the [docs](https://sanitypress.dev/docs).

- 1. Clone a new repo from [the GitHub template](https://github.com/nuotsu/sanitypress).
- 2. Star a [new Sanity project](https://sanity.io/manage) and update environment variables.
- 3. Populate the Studio with your content
- 4. Customize the frontend and Sanity schema to your liking.

For detailed instructions, visit the [Getting Started](https://sanitypress.dev/docs/getting-started) page.
21 changes: 21 additions & 0 deletions starter/sanitypress/app/layout.tsx
Original file line number Diff line number Diff line change
@@ -0,0 +1,21 @@
import type { ReactNode } from 'react'
import { Layout, getMetadata } from '@vercel/examples-ui'
import '@vercel/examples-ui/globals.css'

export const metadata = getMetadata({
title: 'SanityPress',
description: 'SanityPress',
})

export default function RootLayout({ children }: { children: ReactNode }) {
return (
<html lang="en">
<head>
<link rel="icon" href="https://fav.farm/🖤" />
</head>
<body>
<Layout path="starter/sanitypress">{children}</Layout>
</body>
</html>
)
}
33 changes: 33 additions & 0 deletions starter/sanitypress/app/page.tsx
Original file line number Diff line number Diff line change
@@ -0,0 +1,33 @@
import { Page, Text, Code, Link, List } from '@vercel/examples-ui'

export default function Home() {
return (
<Page className="flex flex-col gap-12">
<section className="flex flex-col gap-6">
<Text variant="h1">🖤 SanityPress</Text>
<Text>
A fully customizable Next.js and Sanity starter template with Tailwind
CSS and pre-built schema for rapid website development.
</Text>
</section>

<section className="flex flex-col gap-3">
<Text variant="h2">🚀 Get started in minutes</Text>
<List>
<li>
<Link href="https://sanitypress.dev/">Live Demo</Link>
</li>
<li>
<Link href="https://sanitypress.dev/docs">SanityPress Docs</Link>
</li>
<li>
<Link href="https://github.com/nuotsu/sanitypress">
GitHub Repo
</Link>{' '}
(<code>nuotsu/sanitypress</code>)
</li>
</List>
</section>
</Page>
)
}
Loading