Skip to content
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

Feat: Setup Astro site #52

Merged
merged 9 commits into from
Jul 13, 2024
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
39 changes: 0 additions & 39 deletions .github/workflows/deploy.yml

This file was deleted.

98 changes: 49 additions & 49 deletions README.md
Original file line number Diff line number Diff line change
@@ -1,49 +1,49 @@
![fastgql](docs/src/assets/logo_dark.svg)
<div style="align-content: center ">
<a aria-label="License" href="https://github.com/roneli/fastgql/license.md">
<img alt="" src="https://img.shields.io/npm/l/next.svg?style=for-the-badge&labelColor=000000">
<a aria-label="read the docs" href="https://www.fastgql.io">
<img alt="" src="https://img.shields.io/website?down_color=red&down_message=down&label=docs&style=for-the-badge&up_color=green&up_message=available&url=https%3A%2F%2Fwww.fastgql.io&labelColor=000000">
</a>
</div>
## What is fastGQL?
[*fastGQL*](https://github.com/roneli/fastgql) is a Go library that
extends [gqlgen](https://github.com/99designs/gqlgen) to create a blazing-fast GraphQL server that gives you instant,
realtime GraphQL APIs over Postgres.
- **fastgql is based on a Schema first approach** — You get to Define your API using the
GraphQL [Schema Definition Language](http://graphql.org/learn/schema/).
- **fastgql prioritizes extendability** — You can modify resolvers, add your own custom operators and even create your
own database query builder.
- **fastgql enables codegen** — We generate even more of the boring CRUD bits, so you can focus on building your app
even faster!
## Getting Started
- To install fastgql run the command `go get github.com/roneli/fastgql` in your project directory.<br/>
- You could initialize a new project using the recommended folder structure by running this
command `go run github.com/roneli/fastgql init`.
You could find a more comprehensive guide on [gqlgen](https://github.com/99designs/gqlgen) to help you get
started [here](https://gqlgen.com/getting-started/).
We also have a couple of [examples](https://github.com/roneli/fastgql/tree/master/example) that show how fastgql
generates the full API seamlessly.
## Reporting Issues
If you think you've found a bug, or something isn't behaving the way you think it should, please raise
an [issue](https://github.com/roneli/fastgql/issues) on GitHub.
## Contributing
Feel free to open Pull-Request for small fixes and changes. For bigger changes and new builders please open
an [issue](https://github.com/roneli/fastgql/issues) first to prevent double work and discuss relevant stuff.
## Roadmap 🚧
- Integration testing, and generation testing
- configurable database connections, augmenters and better schema control
- Support multiple database (mongodb, cockroachDB, neo4j)
![fastgql](docs/src/assets/logo_light.svg)


<div style="align-content: center ">
<a aria-label="License" href="https://github.com/roneli/fastgql/license.md">
<img alt="" src="https://img.shields.io/npm/l/next.svg?style=for-the-badge&labelColor=000000">
<a aria-label="read the docs" href="https://www.fastgql.io">
<img alt="" src="https://img.shields.io/website?down_color=red&down_message=down&label=docs&style=for-the-badge&up_color=green&up_message=available&url=https%3A%2F%2Fwww.fastgql.io&labelColor=000000">
</a>
</div>

## What is fastGQL?

[*fastGQL*](https://github.com/roneli/fastgql) is a Go library that
extends [gqlgen](https://github.com/99designs/gqlgen) to create a blazing-fast GraphQL server that gives you instant,
realtime GraphQL APIs over Postgres.

- **fastgql is based on a Schema first approach** — You get to Define your API using the
GraphQL [Schema Definition Language](http://graphql.org/learn/schema/).
- **fastgql prioritizes extendability** — You can modify resolvers, add your own custom operators and even create your
own database query builder.
- **fastgql enables codegen** — We generate even more of the boring CRUD bits, so you can focus on building your app
even faster!

## Getting Started

- To install fastgql run the command `go get github.com/roneli/fastgql` in your project directory.<br/>
- You could initialize a new project using the recommended folder structure by running this
command `go run github.com/roneli/fastgql init`.

You could find a more comprehensive guide on [gqlgen](https://github.com/99designs/gqlgen) to help you get
started [here](https://gqlgen.com/getting-started/).
We also have a couple of [examples](https://github.com/roneli/fastgql/tree/master/example) that show how fastgql
generates the full API seamlessly.

## Reporting Issues

If you think you've found a bug, or something isn't behaving the way you think it should, please raise
an [issue](https://github.com/roneli/fastgql/issues) on GitHub.

## Contributing

Feel free to open Pull-Request for small fixes and changes. For bigger changes and new builders please open
an [issue](https://github.com/roneli/fastgql/issues) first to prevent double work and discuss relevant stuff.

## Roadmap 🚧
- Integration testing, and generation testing
- configurable database connections, augmenters and better schema control
- Support multiple database (mongodb, cockroachDB, neo4j)
1 change: 1 addition & 0 deletions docs/.prettierrc
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
{}
167 changes: 100 additions & 67 deletions docs/astro.config.mjs
Original file line number Diff line number Diff line change
@@ -1,67 +1,100 @@
import {defineConfig} from 'astro/config';
import starlight from '@astrojs/starlight';
// Also can be @astrojs/vercel/static
import vercel from '@astrojs/vercel/serverless';

// https://astro.build/config
export default defineConfig({
output: 'server',
adapter: vercel({
webAnalytics: {
enabled: true,
},
maxDuration: 8,
}),
site: 'https://fastgql.com',
base: "/docs",
integrations: [
starlight({
title: '',
social: {
github: 'https://github.com/roneli/fastgql',
},
logo: {
dark: './src/assets/logo_light.svg',
light: './src/assets/logo_dark.svg',
},
sidebar: [
{
label: 'Getting Started',
items: [
{label: 'Introduction', link: '/start/intro'},
{label: 'Setup', link: '/start/setup'},
]
},
{
label: 'Queries',
items: [
{label: 'Querying', link: '/queries/queries'},
{label: 'Filtering', link: '/queries/filtering'},
{label: 'Ordering', link: '/queries/ordering'},
{label: 'Pagination', link: '/queries/pagination'},
{label: 'Aggregation', link: '/queries/aggregation'},
]
},
{
label: 'Mutations',
items: [
{label: 'Insert', link: '/mutations/insert'},
{label: 'Update', link: '/mutations/update'},
{label: 'Delete', link: '/mutations/delete'},
]
},
{
label: 'Schema',
items: [
{label: 'Directives', link: '/schema/directives'},
{label: 'Schema', link: '/schema_schema_fragment'},
],
},
{
label: 'Reference',
autogenerate: {directory: 'reference'},
},
],
}),
],
});
import {defineConfig} from 'astro/config';
import starlight from '@astrojs/starlight';
import vercel from '@astrojs/vercel/static';
import icon from "astro-icon";

import tailwind from "@astrojs/tailwind";

// https://astro.build/config
export default defineConfig({
output: 'static',
adapter: vercel({
webAnalytics: {
enabled: true
},
maxDuration: 8
}),
site: 'https://fastgql.com',
base: "/",
integrations: [starlight({
title: 'FastGQL',
favicon: './favicon.svg',
social: {
github: 'https://github.com/roneli/fastgql'
},
components: {
// override ThemeProvider
ThemeSelect: './src/components/ThemeSelect.astro',
},
logo: {
dark: './src/assets/logo_dark.svg',
light: './src/assets/logo_light.svg',
replacesTitle: true
},
editLink: {
baseUrl: 'https://github.com/roneli/fastgql/tree/master/docs',
},
customCss: ['./src/styles/global.css', './src/styles/landing.css'],
lastUpdated: true,
sidebar: [{
label: 'Getting Started',
items: [{
label: 'Introduction',
link: '/start/intro'
}, {
label: 'Setup',
link: '/start/setup',
badge: "New",
}]
}, {
label: 'Queries',
items: [{
label: 'Querying',
link: '/queries/queries'
}, {
label: 'Filtering',
link: '/queries/filtering'
}, {
label: 'Ordering',
link: '/queries/ordering'
}, {
label: 'Pagination',
link: '/queries/pagination'
}, {
label: 'Aggregation',
link: '/queries/aggregation'
}]
}, {
label: 'Mutations',
items: [{
label: 'Insert',
link: '/mutations/insert'
}, {
label: 'Update',
link: '/mutations/update'
}, {
label: 'Delete',
link: '/mutations/delete'
}]
}, {
label: 'Schema',
items: [
{
label: 'Interfaces',
link: '/schema/interfaces',
badge: {text: 'Experimental', variant: 'caution'},
}, {
label: 'Directives',
link: '/schema/directives'
}, {
label: 'Schema',
link: '/schema/schema'
}]
}, {
label: 'Reference',
autogenerate: {
directory: 'reference'
}
}]
}), icon(), tailwind()]
});
49 changes: 30 additions & 19 deletions docs/package.json
Original file line number Diff line number Diff line change
@@ -1,20 +1,31 @@
{
"name": "docs",
"type": "module",
"version": "0.0.1",
"scripts": {
"dev": "astro dev --watch",
"start": "astro dev",
"build": "astro check && astro build",
"preview": "astro preview",
"astro": "astro"
},
"dependencies": {
"@astrojs/check": "^0.3.4",
"@astrojs/starlight": "^0.15.1",
"@astrojs/vercel": "^7.3.5",
"astro": "^4.0.1",
"sharp": "^0.32.5",
"typescript": "^5.3.3"
}
{
"name": "docs",
"type": "module",
"version": "0.0.1",
"scripts": {
"dev": "astro dev --watch",
"start": "astro dev",
"build": "astro check && astro build",
"preview": "astro preview",
"astro": "astro"
},
"dependencies": {
"@astrojs/check": "^0.3.4",
"@astrojs/image": "^0.18.0",
"@astrojs/starlight": "^0.15.1",
"@astrojs/tailwind": "^5.1.0",
"@astrojs/vercel": "^7.3.5",
"astro": "^4.0.1",
"astro-icon": "^1.1.0",
"sharp": "^0.32.5",
"tailwindcss": "^3.4.1",
"tailwindcss-fluid-type": "^2.0.3",
"tiny-invariant": "^1.3.3",
"typescript": "^5.3.3"
},
"devDependencies": {
"@iconify-json/mdi": "^1.1.64",
"prettier": "^3.2.5",
"prettier-plugin-astro": "^0.13.0"
}
}
Loading
Loading