Skip to content

Commit 22cb58a

Browse files
committed
gen astro docs
1 parent 3976096 commit 22cb58a

18 files changed

+8377
-82
lines changed

apps/astro-docs/.gitignore

Lines changed: 21 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,21 @@
1+
# build output
2+
dist/
3+
# generated types
4+
.astro/
5+
6+
# dependencies
7+
node_modules/
8+
9+
# logs
10+
npm-debug.log*
11+
yarn-debug.log*
12+
yarn-error.log*
13+
pnpm-debug.log*
14+
15+
16+
# environment variables
17+
.env
18+
.env.production
19+
20+
# macOS-specific files
21+
.DS_Store
Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,4 @@
1+
{
2+
"recommendations": ["astro-build.astro-vscode"],
3+
"unwantedRecommendations": []
4+
}

apps/astro-docs/.vscode/launch.json

Lines changed: 11 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,11 @@
1+
{
2+
"version": "0.2.0",
3+
"configurations": [
4+
{
5+
"command": "./node_modules/.bin/astro dev",
6+
"name": "Development server",
7+
"request": "launch",
8+
"type": "node-terminal"
9+
}
10+
]
11+
}

apps/astro-docs/README.md

Lines changed: 55 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,55 @@
1+
# Starlight Starter Kit: Basics
2+
3+
[![Built with Starlight](https://astro.badg.es/v2/built-with-starlight/tiny.svg)](https://starlight.astro.build)
4+
5+
```
6+
npm create astro@latest -- --template starlight
7+
```
8+
9+
[![Open in StackBlitz](https://developer.stackblitz.com/img/open_in_stackblitz.svg)](https://stackblitz.com/github/withastro/starlight/tree/main/examples/basics)
10+
[![Open with CodeSandbox](https://assets.codesandbox.io/github/button-edit-lime.svg)](https://codesandbox.io/p/sandbox/github/withastro/starlight/tree/main/examples/basics)
11+
[![Deploy to Netlify](https://www.netlify.com/img/deploy/button.svg)](https://app.netlify.com/start/deploy?repository=https://github.com/withastro/starlight&create_from_path=examples/basics)
12+
[![Deploy with Vercel](https://vercel.com/button)](https://vercel.com/new/clone?repository-url=https%3A%2F%2Fgithub.com%2Fwithastro%2Fstarlight%2Ftree%2Fmain%2Fexamples%2Fbasics&project-name=my-starlight-docs&repository-name=my-starlight-docs)
13+
14+
> 🧑‍🚀 **Seasoned astronaut?** Delete this file. Have fun!
15+
16+
## 🚀 Project Structure
17+
18+
Inside of your Astro + Starlight project, you'll see the following folders and files:
19+
20+
```
21+
.
22+
├── public/
23+
├── src/
24+
│ ├── assets/
25+
│ ├── content/
26+
│ │ ├── docs/
27+
│ │ └── config.ts
28+
│ └── env.d.ts
29+
├── astro.config.mjs
30+
├── package.json
31+
└── tsconfig.json
32+
```
33+
34+
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.
35+
36+
Images can be added to `src/assets/` and embedded in Markdown with a relative link.
37+
38+
Static assets, like favicons, can be placed in the `public/` directory.
39+
40+
## 🧞 Commands
41+
42+
All commands are run from the root of the project, from a terminal:
43+
44+
| Command | Action |
45+
| :------------------------ | :----------------------------------------------- |
46+
| `npm install` | Installs dependencies |
47+
| `npm run dev` | Starts local dev server at `localhost:4321` |
48+
| `npm run build` | Build your production site to `./dist/` |
49+
| `npm run preview` | Preview your build locally, before deploying |
50+
| `npm run astro ...` | Run CLI commands like `astro add`, `astro check` |
51+
| `npm run astro -- --help` | Get help using the Astro CLI |
52+
53+
## 👀 Want to learn more?
54+
55+
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).

apps/astro-docs/astro.config.mjs

Lines changed: 39 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,39 @@
1+
import starlight from '@astrojs/starlight';
2+
import tailwind from '@astrojs/tailwind';
3+
import { pluginLineNumbers } from '@expressive-code/plugin-line-numbers';
4+
import { defineConfig } from 'astro/config';
5+
6+
// https://astro.build/config
7+
export default defineConfig({
8+
integrations: [
9+
starlight({
10+
title: 'Angular Three',
11+
social: {
12+
github: 'https://github.com/angular-threejs/angular-three',
13+
},
14+
sidebar: [
15+
{
16+
label: 'Guides',
17+
items: [
18+
// Each item here is one entry in the navigation menu.
19+
{
20+
label: 'Example Guide',
21+
slug: 'guides/example',
22+
},
23+
],
24+
},
25+
{
26+
label: 'Reference',
27+
autogenerate: {
28+
directory: 'reference',
29+
},
30+
},
31+
],
32+
expressiveCode: {
33+
themes: ['dark-plus', 'light-plus'],
34+
plugins: [pluginLineNumbers()],
35+
},
36+
}),
37+
tailwind(),
38+
],
39+
});

apps/astro-docs/package.json

Lines changed: 25 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,25 @@
1+
{
2+
"name": "docs",
3+
"type": "module",
4+
"version": "0.0.1",
5+
"scripts": {
6+
"dev": "astro dev",
7+
"start": "astro dev",
8+
"build": "astro check && astro build",
9+
"preview": "astro preview",
10+
"astro": "astro"
11+
},
12+
"dependencies": {
13+
"@astrojs/check": "^0.8.2",
14+
"@astrojs/starlight": "^0.25.1",
15+
"@astrojs/tailwind": "^5.1.0",
16+
"astro": "^4.10.2",
17+
"sharp": "^0.32.5",
18+
"tailwindcss": "^3.4.6",
19+
"typescript": "^5.5.3"
20+
},
21+
"nx": {},
22+
"devDependencies": {
23+
"@expressive-code/plugin-line-numbers": "^0.35.3"
24+
}
25+
}

0 commit comments

Comments
 (0)