Skip to content

Commit

Permalink
second commit
Browse files Browse the repository at this point in the history
  • Loading branch information
Ze7111 committed Jul 20, 2024
1 parent 9845100 commit 42123dc
Show file tree
Hide file tree
Showing 10 changed files with 281 additions and 21 deletions.
50 changes: 39 additions & 11 deletions astro.config.mjs
Original file line number Diff line number Diff line change
@@ -1,27 +1,55 @@
import { defineConfig } from 'astro/config';
import starlight from '@astrojs/starlight';
import axios from 'axios';

async function fetchGrammar() {
const url = 'https://raw.githubusercontent.com/kneorain/helix-highlighter/main/syntaxes/helix.tmLanguage.json';
const response = await axios.get(url);
return response.data;
}

const grammar = await fetchGrammar();

// https://astro.build/config
export default defineConfig({
integrations: [
starlight({
title: 'My Docs',
social: {
github: 'https://github.com/withastro/starlight',
},
title: 'Helix',

logo: {
src: "/public/favicon.svg",
replacesTitle: false,
},
editLink: {
baseUrl: 'https://github.com/kneorain/helix-api-docs/edit/main/src/content/docs',
},
social: {
github: 'https://github.com/kneorain/helix',
},
customCss: ["/src/styles/docstyle.css"],
expressiveCode: {
themes: ['one-dark-pro', 'one-light'],
shiki: {
langs: [
grammar
],
},
styleOverrides: { borderRadius: '0.2rem' },
},
sidebar: [
{
label: 'Guides',
items: [
// Each item here is one entry in the navigation menu.
{ label: 'Example Guide', slug: 'guides/example' },
],
label: 'Internal Reference',
badge: 'New',
autogenerate: { directory: 'internal' },
},
{
label: 'Reference',
autogenerate: { directory: 'reference' },
label: 'Toolchain API',
badge: 'Wip',
autogenerate: { directory: 'toolchain' },
},
],
}),
],
});


Binary file modified bun.lockb
Binary file not shown.
3 changes: 2 additions & 1 deletion package.json
Original file line number Diff line number Diff line change
Expand Up @@ -10,10 +10,11 @@
"astro": "astro"
},
"dependencies": {
"@astrojs/check": "^0.8.2",
"@astrojs/starlight": "^0.25.1",
"astro": "^4.10.2",
"axios": "^1.7.2",
"sharp": "^0.32.5",
"@astrojs/check": "^0.8.2",
"typescript": "^5.5.3"
}
}
19 changes: 18 additions & 1 deletion public/favicon.svg
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading

0 comments on commit 42123dc

Please sign in to comment.