Skip to content

feat: rewrite homepage with vitepress #186

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

Merged
merged 31 commits into from
Jul 15, 2024
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
31 commits
Select commit Hold shift + click to select a range
731e10d
Added basic vitepress setup
zoey-kaiser Jul 10, 2024
463b7a4
added basic themeing
zoey-kaiser Jul 10, 2024
e7e3a20
began changing nav routes
zoey-kaiser Jul 10, 2024
d83b82e
added linter and new ci workflow
zoey-kaiser Jul 10, 2024
bf91bd2
added tailwindcss, the old terminal and some basic feature cards
zoey-kaiser Jul 10, 2024
0801c4d
added docs deploy flow
zoey-kaiser Jul 10, 2024
d0c95db
fix: build error
zoey-kaiser Jul 10, 2024
b1709cc
fix: build again?
zoey-kaiser Jul 10, 2024
45f8f43
fix: build errors
zoey-kaiser Jul 10, 2024
c69e23d
set correct base url
zoey-kaiser Jul 10, 2024
56da9b6
use divs instead of templates for hidding
zoey-kaiser Jul 10, 2024
9a90d8f
correctly reset lines on reload
zoey-kaiser Jul 10, 2024
bddbf7b
set scroll down offset back to 100
zoey-kaiser Jul 10, 2024
c4f5b87
added old sidebase docs to new setup
zoey-kaiser Jul 10, 2024
24b116e
Finished basic landing features overview
zoey-kaiser Jul 10, 2024
d4f42e7
fix: lint
zoey-kaiser Jul 10, 2024
c6c56b8
fix: dead links
zoey-kaiser Jul 10, 2024
caec4ed
added vscode settings folder
zoey-kaiser Jul 10, 2024
8d1d783
added sidebase logos and icons to the feature boxes
zoey-kaiser Jul 11, 2024
a707e0d
small style improvements
zoey-kaiser Jul 11, 2024
a242010
added SpinningGradient background
zoey-kaiser Jul 11, 2024
8da1804
Adjusted Nav routes
zoey-kaiser Jul 11, 2024
5bb55e3
fix terminal on page refresh
zoey-kaiser Jul 11, 2024
630791b
added favicon
zoey-kaiser Jul 11, 2024
3620be9
changed title template
zoey-kaiser Jul 11, 2024
968e294
changed title again
zoey-kaiser Jul 11, 2024
6c40248
test out redirect
zoey-kaiser Jul 11, 2024
63f3dda
added NuxtAuth redirects
zoey-kaiser Jul 11, 2024
d091c6f
added readme and updated preview image
zoey-kaiser Jul 11, 2024
eb6d993
added a fallback image if the terminal does not load
zoey-kaiser Jul 11, 2024
c8a0935
prepared pipelines for deplpyment on main branch
zoey-kaiser Jul 15, 2024
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
The table of contents is too big for display.
Diff view
Diff view
  •  
  •  
  •  
84 changes: 0 additions & 84 deletions .drone.yml

This file was deleted.

Binary file modified .github/preview.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
26 changes: 0 additions & 26 deletions .github/workflows/auto-merge.yaml

This file was deleted.

44 changes: 44 additions & 0 deletions .github/workflows/ci.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,44 @@
name: CI

on:
push:
branches: [ main ]
pull_request:
branches: [ main ]

jobs:
lint:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v4
- name: Use Node.js 20.6.1
uses: actions/setup-node@v4
with:
node-version: 20.6.1

- name: Setup
run: npm i -g @antfu/ni

- name: Install
run: nci

- name: Lint
run: nr lint

build:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v4
- name: Use Node.js 20.6.1
uses: actions/setup-node@v4
with:
node-version: 20.6.1

- name: Setup
run: npm i -g @antfu/ni

- name: Install
run: nci

- name: Build
run: nr build
62 changes: 62 additions & 0 deletions .github/workflows/deploy-docs.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,62 @@
name: Deploy Docs

on:
push:
branches: [main]

# Allows you to run this workflow manually from the Actions tab
workflow_dispatch:

# Sets permissions of the GITHUB_TOKEN to allow deployment to GitHub Pages
permissions:
contents: read
pages: write
id-token: write

# Allow only one concurrent deployment, skipping runs queued between the run in-progress and latest queued.
# However, do NOT cancel in-progress runs as we want to allow these production deployments to complete.
concurrency:
group: pages
cancel-in-progress: false

jobs:
# Build job
build:
runs-on: ubuntu-latest
steps:
- name: Checkout
uses: actions/checkout@v4
with:
fetch-depth: 0 # Required to calculate lastUpdated
- name: Install pnpm
uses: pnpm/action-setup@v3
with:
version: 8
- name: Setup Node
uses: actions/setup-node@v4
with:
node-version: 20
cache: pnpm
- name: Setup Pages
uses: actions/configure-pages@v4
- name: Install dependencies
run: pnpm i
- name: Build with VitePress
run: pnpm build
- name: Upload artifact
uses: actions/upload-pages-artifact@v3
with:
path: .vitepress/dist

# Deployment job
deploy:
environment:
name: github-pages
url: ${{ steps.deployment.outputs.page_url }}
needs: build
runs-on: ubuntu-latest
name: Deploy
steps:
- name: Deploy to GitHub Pages
id: deployment
uses: actions/deploy-pages@v4
11 changes: 8 additions & 3 deletions .gitignore
Original file line number Diff line number Diff line change
@@ -1,10 +1,15 @@
## User-specific files
.DS_Store
.idea

## Vite Press related
.vitepress/cache
.vitepress/dist

node_modules
*.iml
.idea
*.log*
.nuxt
.vscode
.DS_Store
coverage
dist
sw.*
Expand Down
1 change: 1 addition & 0 deletions .npmrc
Original file line number Diff line number Diff line change
@@ -1,2 +1,3 @@
shamefully-hoist=true
strict-peer-dependencies=false
ignore-workspace-root-check=true
41 changes: 41 additions & 0 deletions .vitepress/config.mts
Original file line number Diff line number Diff line change
@@ -0,0 +1,41 @@
import { defineConfig } from 'vitepress'
import { routes as navRoutes } from './routes/navbar'
import { routes as sidebarRoutes } from './routes/sidebar'

// https://vitepress.dev/reference/site-config
export default defineConfig({
title: 'sidebase',
titleTemplate: ':title - by SIDESTREAM',
description: 'The productive way to build fullstack Nuxt 3 applications.',
srcDir: 'src',
base: '/',
cleanUrls: true,
lang: 'en-US',
appearance: 'dark',
lastUpdated: true,
head: [['link', { rel: 'icon', href: '/favicon.ico' }]],
themeConfig: {
logo: {
light: '/logo-light.svg',
dark: '/logo-dark.svg'
},
nav: navRoutes,
sidebar: sidebarRoutes,
socialLinks: [
{ icon: 'github', link: 'https://github.com/sidebase' },
{ icon: 'x', link: 'https://twitter.com/sidebase_io' },
{ icon: 'discord', link: 'https://discord.gg/VzABbVsqAc' },
],
footer: {
message: 'Released under the MIT License.',
copyright: 'Developed by SIDESTREAM',
},
search: {
provider: 'local',
},
editLink: {
pattern: 'https://github.com/sidebase/docs/tree/main/src/:path',
text: 'Edit this page on GitHub'
}
},
})
25 changes: 25 additions & 0 deletions .vitepress/routes/navbar.ts
Original file line number Diff line number Diff line change
@@ -0,0 +1,25 @@
import type { DefaultTheme } from 'vitepress'

export const routes: DefaultTheme.Config['nav'] = [
{
text: 'Development Kit',
items: [
{
text: 'Getting started',
link: '/sidebase/welcome',
},
{
text: 'Components',
link: '/sidebase/components',
},
{
text: 'Resources',
link: '/sidebase/resources',
},
],
},
{
text: 'NuxtAuth',
link: 'https://auth.sidebase.io'
},
]
88 changes: 88 additions & 0 deletions .vitepress/routes/sidebar.ts
Original file line number Diff line number Diff line change
@@ -0,0 +1,88 @@
import type { DefaultTheme } from 'vitepress'

export const routes: DefaultTheme.Config['sidebar'] = {
'/sidebase': [
{
text: 'Welcome',
base: '/sidebase/welcome',
items: [
{
text: 'Introduction',
link: '/',
},
{
text: 'Stacks',
link: '/stacks',
},
{
text: 'Quick Start',
link: '/quick-start',
},
{
text: 'Getting Help',
link: '/getting-help',
},
{
text: 'FAQ',
link: '/faq',
},
],
},
{
text: 'Components',
base: '/sidebase/components',
items: [
{
text: 'Overview',
link: '/',
},
{
text: 'Nuxt 3',
link: '/nuxt-3',
},
{
text: 'Typescript',
link: '/typescript',
},
{
text: 'Prisma ORM',
link: '/prisma',
},
{
text: 'tRPC',
link: '/trpc',
},
{
text: 'Nuxt Auth',
link: '/nuxt-auth',
},
{
text: 'Tailwind CSS',
link: '/tailwindcss',
},
],
},
{
text: 'Resources',
base: '/sidebase/resources',
items: [
{
text: 'Overview',
link: '/',
},
{
text: 'Coding Setup',
link: '/coding-setup',
},
{
text: 'Breakpoint Debugging',
link: '/breakpoint-debugging',
},
{
text: 'Commands Cheat sheet',
link: '/commands',
},
],
},
],
}
Loading