Skip to content

Commit

Permalink
feat!: Rewrite docs to Astro.js and starlight
Browse files Browse the repository at this point in the history
  • Loading branch information
Uzaaft authored and mehalter committed Oct 6, 2023
1 parent 71e86a3 commit 097a703
Show file tree
Hide file tree
Showing 925 changed files with 4,704 additions and 126,700 deletions.
122 changes: 14 additions & 108 deletions .gitignore
Original file line number Diff line number Diff line change
@@ -1,116 +1,22 @@
# Logs
logs
*.log
npm-debug.log*
yarn-debug.log*
yarn-error.log*
lerna-debug.log*

# Diagnostic reports (https://nodejs.org/api/report.html)
report.[0-9]*.[0-9]*.[0-9]*.[0-9]*.json

# Runtime data
pids
*.pid
*.seed
*.pid.lock

# Directory for instrumented libs generated by jscoverage/JSCover
lib-cov

# Coverage directory used by tools like istanbul
coverage
*.lcov

# nyc test coverage
.nyc_output
# build output
dist/
# generated types
.astro/

# Grunt intermediate storage (https://gruntjs.com/creating-plugins#storing-task-files)
.grunt

# Bower dependency directory (https://bower.io/)
bower_components

# node-waf configuration
.lock-wscript

# Compiled binary addons (https://nodejs.org/api/addons.html)
build/Release

# Dependency directories
# dependencies
node_modules/
jspm_packages/

# TypeScript v1 declaration files
typings/

# TypeScript cache
*.tsbuildinfo

# Optional npm cache directory
.npm

# Optional eslint cache
.eslintcache

# Microbundle cache
.rpt2_cache/
.rts2_cache_cjs/
.rts2_cache_es/
.rts2_cache_umd/

# Optional REPL history
.node_repl_history

# Output of 'npm pack'
*.tgz
# logs
npm-debug.log*
yarn-debug.log*
yarn-error.log*
pnpm-debug.log*

# Yarn Integrity file
.yarn-integrity

# dotenv environment variables file
# environment variables
.env
.env.test
.env.local
.env.development.local
.env.test.local
.env.production.local

# parcel-bundler cache (https://parceljs.org/)
.cache

# Next.js build output
.next

# Nuxt.js build / generate output
.nuxt
dist

# Gatsby files
.cache/
# Comment in the public line in if your project uses Gatsby and *not* Next.js
# https://nextjs.org/blog/next-9-1#public-directory-support
# public

# vuepress build output
.vuepress/dist

# Serverless directories
.serverless/

# FuseBox cache
.fusebox/

# DynamoDB Local files
.dynamodb/

# TernJS port file
.tern-port

# Docusaurus files
/build
.docusaurus
.cache-loader
.env.production

# Misc
# macOS-specific files
.DS_Store
.vercel
21 changes: 0 additions & 21 deletions LICENSE

This file was deleted.

54 changes: 41 additions & 13 deletions README.md
Original file line number Diff line number Diff line change
@@ -1,25 +1,53 @@
# AstroNvim Website
# Starlight Starter Kit: Basics

This website is built using [Docusaurus 2](https://docusaurus.io/), a modern static website generator.

### Installation
[![Built with Starlight](https://astro.badg.es/v2/built-with-starlight/tiny.svg)](https://starlight.astro.build)

```
$ yarn
npm create astro@latest -- --template starlight
```

### Local Development
[![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)

```
$ yarn start
```
> 🧑‍🚀 **Seasoned astronaut?** Delete this file. Have fun!
This command starts a local development server and opens up a browser window. Most changes are reflected live without having to restart the server.
## 🚀 Project Structure

### Build
Inside of your Astro + Starlight project, you'll see the following folders and files:

```
$ yarn build
.
├── public/
├── src/
│ ├── assets/
│ ├── content/
│ │ ├── docs/
│ │ └── config.ts
│ └── env.d.ts
├── astro.config.mjs
├── package.json
└── tsconfig.json
```

This command generates static content into the `build` directory and can be served using any static contents hosting service.
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.

Static assets, like favicons, can be placed in the `public/` directory.

## 🧞 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).
79 changes: 79 additions & 0 deletions astro.config.mjs
Original file line number Diff line number Diff line change
@@ -0,0 +1,79 @@
import { defineConfig } from "astro/config";
import starlight from "@astrojs/starlight";

import tailwind from "@astrojs/tailwind";

// https://astro.build/config
export default defineConfig({
site: "https://astrodocs-v2.vercel.app",
integrations: [
starlight({
title: "AstroNvim",
logo: {
src: "./src/assets/logo/astronvim.svg",
},
customCss: [
// Path to your Tailwind base styles:
"./src/tailwind.css",
],
social: {
github: "https://github.com/AstroNvim/AstroNvim",
// reddit: "https://www.reddit.com/r/AstroNvim/",
discord: "https://discord.astronvim.com",
twitter: "https://twitter.com/AstroNvim",
mastodon: "https://hachyderm.io/@AstroNvim",
},
sidebar: [
{
label: "Getting started",
link: "/",
collapsed: true,
},
{
label: "Basic Usage",
collapsed: true,
autogenerate: {
directory: "basic-usage",
},
},
{
label: "Configuration",
collapsed: true,
autogenerate: {
directory: "Configuration",
},
},
{
label: "Recipes",
collapsed: true,
autogenerate: {
directory: "Recipes",
},
},
{
label: "Acknowledgements",
link: "/acknowledgements",
collapsed: true,
},
{
label: "Code of Conduct",
collapsed: true,
link: "/code_of_conduct",
},
{
label: "Frequently asked questions",
collapsed: true,
link: "/faq",
},
{
label: "Core Lua API Documentation",
link: "https://api.astronvim.com",
},
],
}),
tailwind({
// Disable the default base styles:
applyBaseStyles: false,
}),
],
});
3 changes: 0 additions & 3 deletions babel.config.js

This file was deleted.

Loading

0 comments on commit 097a703

Please sign in to comment.