-
Notifications
You must be signed in to change notification settings - Fork 259
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Switch documentation website from Nuxt to Astro
- Loading branch information
Showing
36 changed files
with
2,914 additions
and
6,730 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,21 @@ | ||
# build output | ||
dist/ | ||
# generated types | ||
.astro/ | ||
|
||
# dependencies | ||
node_modules/ | ||
|
||
# logs | ||
npm-debug.log* | ||
yarn-debug.log* | ||
yarn-error.log* | ||
pnpm-debug.log* | ||
|
||
|
||
# environment variables | ||
.env | ||
.env.production | ||
|
||
# macOS-specific files | ||
.DS_Store |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,34 +1,53 @@ | ||
# Chproxy documentation | ||
# Starlight Starter Kit: Basics | ||
|
||
The documentation website is build with Nuxt and the official docs theme. | ||
[![Built with Starlight](https://astro.badg.es/v2/built-with-starlight/tiny.svg)](https://starlight.astro.build) | ||
|
||
It is automatically deployed on each commit on the `main` branch, through | ||
Render. | ||
``` | ||
npm create astro@latest -- --template starlight | ||
``` | ||
|
||
# CONTRIBUTING | ||
[![Open in StackBlitz](https://developer.stackblitz.com/img/open_in_stackblitz.svg)](https://stackblitz.com/github/withastro/starlight/tree/main/examples/basics) | ||
[![Open with CodeSandbox](https://assets.codesandbox.io/github/button-edit-lime.svg)](https://codesandbox.io/p/sandbox/github/withastro/starlight/tree/main/examples/basics) | ||
|
||
## Ordering links in the sidebar | ||
> 🧑🚀 **Seasoned astronaut?** Delete this file. Have fun! | ||
Each page should be given a unique `position`, that will determine where it will | ||
be positioned in the sidebar. Each page can also have a `category`, to group | ||
similar pages together. | ||
## 🚀 Project Structure | ||
|
||
Note that the `position` is relative to the top of the sidebar, not to the top | ||
of the parent category. | ||
Inside of your Astro + Starlight project, you'll see the following folders and files: | ||
|
||
**Tip:** Span `position` values on various hundreds, so you can more easily | ||
reorder links in a given category. For example, all links in the first category | ||
should be `101`, `102`, etc and links in the third category should be `301`, | ||
`302`, etc. | ||
``` | ||
. | ||
├── public/ | ||
├── src/ | ||
│ ├── assets/ | ||
│ ├── content/ | ||
│ │ ├── docs/ | ||
│ │ └── config.ts | ||
│ └── env.d.ts | ||
├── astro.config.mjs | ||
├── package.json | ||
└── tsconfig.json | ||
``` | ||
|
||
Starlight looks for `.md` or `.mdx` files in the `src/content/docs/` directory. Each file is exposed as a route based on its file name. | ||
|
||
Images can be added to `src/assets/` and embedded in Markdown with a relative link. | ||
|
||
## TODO: | ||
Static assets, like favicons, can be placed in the `public/` directory. | ||
|
||
- Configure Render for deployment | ||
- Configure Render for Pull Requests | ||
- Can we make it smart and only re-render if changes in the docs, not if | ||
changes in the code? | ||
- Configure Algolia DocSearch | ||
- Need to add a logo | ||
- Replace the manual copy/paste of files with dynamic links | ||
## 🧞 Commands | ||
|
||
All commands are run from the root of the project, from a terminal: | ||
|
||
| Command | Action | | ||
| :------------------------ | :----------------------------------------------- | | ||
| `npm install` | Installs dependencies | | ||
| `npm run dev` | Starts local dev server at `localhost:4321` | | ||
| `npm run build` | Build your production site to `./dist/` | | ||
| `npm run preview` | Preview your build locally, before deploying | | ||
| `npm run astro ...` | Run CLI commands like `astro add`, `astro check` | | ||
| `npm run astro -- --help` | Get help using the Astro CLI | | ||
|
||
## 👀 Want to learn more? | ||
|
||
Check out [Starlight’s docs](https://starlight.astro.build/), read [the Astro documentation](https://docs.astro.build), or jump into the [Astro Discord server](https://astro.build/chat). |
This file was deleted.
Oops, something went wrong.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,63 @@ | ||
import { defineConfig } from 'astro/config'; | ||
import starlight from '@astrojs/starlight'; | ||
|
||
// https://astro.build/config | ||
export default defineConfig({ | ||
site: 'https://www.chproxy.org', | ||
integrations: [ | ||
starlight({ | ||
title: 'Chproxy', | ||
description: 'Chproxy is an HTTP proxy and load balancer for ClickHouse', | ||
social: { | ||
github: 'https://github.com/ContentSquare/chproxy', | ||
twitter: 'https://twitter.com/contentsquarerd' | ||
}, | ||
editLink: { | ||
baseUrl: 'https://github.com/ContentSquare/chproxy/edit/master/docs/', | ||
}, | ||
logo: { | ||
dark: './src/assets/logo-white.svg', | ||
light: './src/assets/logo-black.svg', | ||
replacesTitle: true, | ||
}, | ||
customCss: [ | ||
// Relative path to your custom CSS file | ||
'./src/styles/custom.css', | ||
], | ||
defaultLocale: 'root', | ||
locales: { | ||
// English docs in `src/content/docs/en/` | ||
root: { | ||
label: 'English', | ||
lang: 'en' | ||
}, | ||
// Simplified Chinese docs in `src/content/docs/zh/` | ||
cn: { | ||
label: '简体中文', | ||
lang: 'zh-CN', | ||
} | ||
}, | ||
sidebar: [ | ||
{ | ||
label: 'Guides', | ||
items: [ | ||
{ label: 'Introduction', link: '/' }, | ||
{ label: 'Installation', link: '/install/' }, | ||
{ label: 'Quick start', link: '/getting_started/' }, | ||
{ label: 'Changelog', link: '/changelog/' }, | ||
{ label: 'History', link: '/history/' }, | ||
{ label: 'FAQ', link: '/faq/' } | ||
], | ||
}, | ||
{ | ||
label: 'Configuration', | ||
autogenerate: { directory: 'configuration' } | ||
}, | ||
{ | ||
label: 'Use cases', | ||
autogenerate: { directory: 'use-cases' } | ||
}, | ||
], | ||
}), | ||
], | ||
}); |
This file was deleted.
Oops, something went wrong.
This file was deleted.
Oops, something went wrong.
Oops, something went wrong.