Skip to content

Commit

Permalink
Config doc (#4604)
Browse files Browse the repository at this point in the history
* Add cache introduction

* typo fix

* some routing fixes

* config doc

* more route fixes

* minor fix

* snap fix

* chore(dependencies): updated changesets for modified dependencies

Co-authored-by: github-actions[bot] <github-actions[bot]@users.noreply.github.com>
  • Loading branch information
gilgardosh and github-actions[bot] authored Sep 29, 2022
1 parent 5dbf8ed commit ffb3014
Show file tree
Hide file tree
Showing 23 changed files with 232 additions and 1 deletion.
7 changes: 7 additions & 0 deletions .changeset/@graphql-mesh_graphql-4604-dependencies.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,7 @@
---
"@graphql-mesh/graphql": patch
---
dependencies updates:
- Updated dependency [`@graphql-tools/[email protected]` ↗︎](https://www.npmjs.com/package/@graphql-tools/url-loader/v/7.16.4) (from `7.16.2`, in `dependencies`)
- Updated dependency [`@graphql-tools/[email protected]` ↗︎](https://www.npmjs.com/package/@graphql-tools/wrap/v/9.2.3) (from `9.2.1`, in `dependencies`)
- Updated dependency [`@graphql-tools/[email protected]` ↗︎](https://www.npmjs.com/package/@graphql-tools/delegate/v/9.0.8) (from `9.0.6`, in `dependencies`)
Original file line number Diff line number Diff line change
@@ -0,0 +1,5 @@
---
"@graphql-mesh/merger-federation": patch
---
dependencies updates:
- Updated dependency [`@graphql-tools/[email protected]` ↗︎](https://www.npmjs.com/package/@graphql-tools/wrap/v/9.2.3) (from `9.2.1`, in `dependencies`)
Original file line number Diff line number Diff line change
@@ -0,0 +1,7 @@
---
"@graphql-mesh/merger-stitching": patch
---
dependencies updates:
- Updated dependency [`@graphql-tools/[email protected]` ↗︎](https://www.npmjs.com/package/@graphql-tools/stitch/v/8.7.13) (from `8.7.11`, in `dependencies`)
- Updated dependency [`@graphql-tools/[email protected]` ↗︎](https://www.npmjs.com/package/@graphql-tools/delegate/v/9.0.8) (from `9.0.6`, in `dependencies`)
- Updated dependency [`@graphql-tools/[email protected]` ↗︎](https://www.npmjs.com/package/@graphql-tools/stitching-directives/v/2.3.11) (from `2.3.9`, in `dependencies`)
5 changes: 5 additions & 0 deletions .changeset/@graphql-mesh_mysql-4604-dependencies.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,5 @@
---
"@graphql-mesh/mysql": patch
---
dependencies updates:
- Updated dependency [`@graphql-tools/[email protected]` ↗︎](https://www.npmjs.com/package/@graphql-tools/delegate/v/9.0.8) (from `9.0.6`, in `dependencies`)
5 changes: 5 additions & 0 deletions .changeset/@graphql-mesh_odata-4604-dependencies.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,5 @@
---
"@graphql-mesh/odata": patch
---
dependencies updates:
- Updated dependency [`@graphql-tools/[email protected]` ↗︎](https://www.npmjs.com/package/@graphql-tools/delegate/v/9.0.8) (from `9.0.6`, in `dependencies`)
5 changes: 5 additions & 0 deletions .changeset/@graphql-mesh_postgraphile-4604-dependencies.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,5 @@
---
"@graphql-mesh/postgraphile": patch
---
dependencies updates:
- Updated dependency [`@graphql-tools/[email protected]` ↗︎](https://www.npmjs.com/package/@graphql-tools/delegate/v/9.0.8) (from `9.0.6`, in `dependencies`)
7 changes: 7 additions & 0 deletions .changeset/@graphql-mesh_runtime-4604-dependencies.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,7 @@
---
"@graphql-mesh/runtime": patch
---
dependencies updates:
- Updated dependency [`@graphql-tools/[email protected]` ↗︎](https://www.npmjs.com/package/@graphql-tools/delegate/v/9.0.8) (from `9.0.6`, in `dependencies`)
- Updated dependency [`@graphql-tools/[email protected]` ↗︎](https://www.npmjs.com/package/@graphql-tools/batch-delegate/v/8.4.1) (from `8.3.9`, in `dependencies`)
- Updated dependency [`@graphql-tools/[email protected]` ↗︎](https://www.npmjs.com/package/@graphql-tools/wrap/v/9.2.3) (from `9.2.1`, in `dependencies`)
Original file line number Diff line number Diff line change
@@ -0,0 +1,6 @@
---
"@graphql-mesh/transform-encapsulate": patch
---
dependencies updates:
- Updated dependency [`@graphql-tools/[email protected]` ↗︎](https://www.npmjs.com/package/@graphql-tools/delegate/v/9.0.8) (from `9.0.6`, in `dependencies`)
- Updated dependency [`@graphql-tools/[email protected]` ↗︎](https://www.npmjs.com/package/@graphql-tools/wrap/v/9.2.3) (from `9.2.1`, in `dependencies`)
Original file line number Diff line number Diff line change
@@ -0,0 +1,6 @@
---
"@graphql-mesh/transform-federation": patch
---
dependencies updates:
- Updated dependency [`@graphql-tools/[email protected]` ↗︎](https://www.npmjs.com/package/@graphql-tools/stitching-directives/v/2.3.11) (from `2.3.9`, in `dependencies`)
- Updated dependency [`@graphql-tools/[email protected]` ↗︎](https://www.npmjs.com/package/@graphql-tools/delegate/v/9.0.8) (from `9.0.6`, in `dependencies`)
Original file line number Diff line number Diff line change
@@ -0,0 +1,6 @@
---
"@graphql-mesh/transform-filter-schema": patch
---
dependencies updates:
- Updated dependency [`@graphql-tools/[email protected]` ↗︎](https://www.npmjs.com/package/@graphql-tools/wrap/v/9.2.3) (from `9.2.1`, in `dependencies`)
- Updated dependency [`@graphql-tools/[email protected]` ↗︎](https://www.npmjs.com/package/@graphql-tools/delegate/v/9.0.8) (from `9.0.6`, in `dependencies`)
Original file line number Diff line number Diff line change
@@ -0,0 +1,6 @@
---
"@graphql-mesh/transform-hoist-field": patch
---
dependencies updates:
- Updated dependency [`@graphql-tools/[email protected]` ↗︎](https://www.npmjs.com/package/@graphql-tools/delegate/v/9.0.8) (from `9.0.6`, in `dependencies`)
- Updated dependency [`@graphql-tools/[email protected]` ↗︎](https://www.npmjs.com/package/@graphql-tools/wrap/v/9.2.3) (from `9.2.1`, in `dependencies`)
Original file line number Diff line number Diff line change
@@ -0,0 +1,6 @@
---
"@graphql-mesh/transform-naming-convention": patch
---
dependencies updates:
- Updated dependency [`@graphql-tools/[email protected]` ↗︎](https://www.npmjs.com/package/@graphql-tools/delegate/v/9.0.8) (from `9.0.6`, in `dependencies`)
- Updated dependency [`@graphql-tools/[email protected]` ↗︎](https://www.npmjs.com/package/@graphql-tools/wrap/v/9.2.3) (from `9.2.1`, in `dependencies`)
Original file line number Diff line number Diff line change
@@ -0,0 +1,6 @@
---
"@graphql-mesh/transform-prefix": patch
---
dependencies updates:
- Updated dependency [`@graphql-tools/[email protected]` ↗︎](https://www.npmjs.com/package/@graphql-tools/delegate/v/9.0.8) (from `9.0.6`, in `dependencies`)
- Updated dependency [`@graphql-tools/[email protected]` ↗︎](https://www.npmjs.com/package/@graphql-tools/wrap/v/9.2.3) (from `9.2.1`, in `dependencies`)
Original file line number Diff line number Diff line change
@@ -0,0 +1,6 @@
---
"@graphql-mesh/transform-rename": patch
---
dependencies updates:
- Updated dependency [`@graphql-tools/[email protected]` ↗︎](https://www.npmjs.com/package/@graphql-tools/delegate/v/9.0.8) (from `9.0.6`, in `dependencies`)
- Updated dependency [`@graphql-tools/[email protected]` ↗︎](https://www.npmjs.com/package/@graphql-tools/wrap/v/9.2.3) (from `9.2.1`, in `dependencies`)
Original file line number Diff line number Diff line change
@@ -0,0 +1,6 @@
---
"@graphql-mesh/transform-type-merging": patch
---
dependencies updates:
- Updated dependency [`@graphql-tools/[email protected]` ↗︎](https://www.npmjs.com/package/@graphql-tools/stitching-directives/v/2.3.11) (from `2.3.9`, in `dependencies`)
- Updated dependency [`@graphql-tools/[email protected]` ↗︎](https://www.npmjs.com/package/@graphql-tools/delegate/v/9.0.8) (from `9.0.6`, in `dependencies`)
6 changes: 6 additions & 0 deletions .changeset/@graphql-mesh_types-4604-dependencies.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,6 @@
---
"@graphql-mesh/types": patch
---
dependencies updates:
- Updated dependency [`@graphql-tools/[email protected]` ↗︎](https://www.npmjs.com/package/@graphql-tools/batch-delegate/v/8.4.1) (from `8.3.9`, in `dependencies`)
- Updated dependency [`@graphql-tools/[email protected]` ↗︎](https://www.npmjs.com/package/@graphql-tools/delegate/v/9.0.8) (from `9.0.6`, in `dependencies`)
5 changes: 5 additions & 0 deletions .changeset/@graphql-mesh_utils-4604-dependencies.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,5 @@
---
"@graphql-mesh/utils": patch
---
dependencies updates:
- Updated dependency [`@graphql-tools/[email protected]` ↗︎](https://www.npmjs.com/package/@graphql-tools/delegate/v/9.0.8) (from `9.0.6`, in `dependencies`)
3 changes: 3 additions & 0 deletions website/next.config.mjs
Original file line number Diff line number Diff line change
Expand Up @@ -23,6 +23,9 @@ export default withGuildDocs({
'/docs/getting-started/introduction': '/docs/getting-started/overview',
'/docs/handlers': '/docs/handlers/handlers-introduction',
'/docs/handlers/available-handlers': '/docs/handlers/handlers-introduction',
'/docs/migration': '/docs/migration/openapi-0.31-0.32',
'/docs/transforms': '/docs/transforms/transforms-introduction',
'/docs/guides': '/docs/guides/extending-unified-schema',
'/docs/plugins': '/docs/plugins/plugins-introduction',
}).map(([from, to]) => ({
source: from,
Expand Down
10 changes: 10 additions & 0 deletions website/src/pages/docs/cache/cache-introduction.mdx
Original file line number Diff line number Diff line change
@@ -0,0 +1,10 @@
# Cache Storages

GraphQL Mesh can apply caching in various strategies:

| Strategy | Docs |
| --------------------- | ------------------------------- |
| File Cache | [docs](/docs/cache/file) |
| LocalForage | [docs](/docs/cache/localforage) |
| CloudFlare Workers KV | [docs](/docs/cache/cfwKv) |
| Redis Cache | [docs](/docs/cache/redis) |
1 change: 1 addition & 0 deletions website/src/pages/docs/cache/meta.json
Original file line number Diff line number Diff line change
@@ -1,4 +1,5 @@
{
"cache-introduction": "Introduction",
"file": "File",
"localforage": "LocalForage",
"cfwKv": "CF Workers KV",
Expand Down
116 changes: 116 additions & 0 deletions website/src/pages/docs/config-reference.mdx
Original file line number Diff line number Diff line change
@@ -0,0 +1,116 @@
import { Callout } from '@theguild/components'

# Config Reference

Commonly, configuration file is named `.meshrc.yaml` and placed in the root of your project.

`yml`, `json`, `.ts`, `.js` and `.cjs` files are also supported.


## `sources`

Mandatory field. Defines the list of your external data sources for your API mesh.

Acceptable external sources, with detailed specific configurations, available in the [Handlers](/docs/handlers) section.


## `transforms`

Defines the list of manipulations to apply to the unified mesh schema.

Available transforms available in the [Transforms](/docs/transforms) section.


## `additionalTypeDefs`

Additional type definitions, or type definitions overrides you wish to add to the schema mesh. [Read more](/docs/getting-started/combine-multiple-sources#setup-hierarchy-with-nested-queries)


## `additionalResolvers`

Additional resolvers, or resolvers overrides you wish to add to the schema mesh. [Read more](/docs/guides/extending-unified-schema#programmatic-additionalresolvers)


## `plugins`

Extend the mesh schema's capabilities with additional [plugins](/docs/plugins/plugins-introduction).


## `additionalEnvelopPlugins`

Additional plugins from [Envelop Ecosystem](https://www.envelop.dev/plugins). [Read more](/docs/plugins/plugins-introduction#additional-plugins)


## `cache`

Configure the [caching strategy](/docs/cache) for your unified schema.


## `serve`

Mesh as a server configuration. [Read more](/docs/getting-started/customize-mesh-server#provide-a-standalone-server-implementation)

### Serve config reference:

import Serve from '../../generated-markdown/ServeConfig.generated.md'

<Serve />


## `sdk`

SDK generation configurations. [Read more](/docs/guides/mesh-sdk#getting-started)

### SDK config reference:

import SDK from '../../generated-markdown/SDKConfig.generated.md'

<SDK />


## `documents`

Provide a query or queries for GraphQL Playground, validation and SDK Generation.
The value can be the file path, glob expression for the file paths or the SDL.
`.js`, `.jsx`, `.graphql`, `.gql`, `.ts` and `.tsx` files are supported.
[Read more](/docs/guides/mesh-sdk#getting-started)


## `customFetch`

Path to a custom W3 Compatible Fetch Implementation. [Example](/docs/handlers/openapi#accepting-one-of-the-cookies-header-or-context-value)


## `logger`

Logger instance that matches `Console` interface of NodeJS.


## `merger`

Merge method. Either 'stitching', 'bare' or 'federation' are acceptable.


## `pubsub`

PubSub Implementation.


## `skipSSLValidation`

Allow connections to an SSL endpoint without certificates (type: `Boolean`).


## `includeHttpDetailsInExtensions`

Include HTTP details to the extensions (type: `Boolean`).


## `codegen`

GraphQL Code Generator Configuration. [Read more](/docs/guides/graphql-code-generator#customizing-the-graphql-code-generator-configuration


## `require`

Loads specific require extensions before running the GraphQL Code Generator and reading the configuration.
2 changes: 1 addition & 1 deletion website/src/pages/docs/handlers/openapi.mdx
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@ import { PackageCmd } from '@theguild/components'

This handler allows you to load remote or local [OpenAPI (2/3) and Swagger](https://swagger.io) schemas.

For migrationg from version `< 0.32` see [migration guide](/docs/migration/openapi-0.31-0.32)
For migrating from version `< 0.32` see [migration guide](/docs/migration/openapi-0.31-0.32)

You can import it using remote/local `.json` or `.yaml`.

Expand Down
1 change: 1 addition & 0 deletions website/src/pages/docs/meta.json
Original file line number Diff line number Diff line change
Expand Up @@ -6,6 +6,7 @@
"transforms": "Transforms",
"plugins": "Plugins",
"cache": "Cache Storages",
"config-reference": "Config Reference",
"cli-commands": "CLI commands",
"migration": "Migration guides",
"extend": {
Expand Down

0 comments on commit ffb3014

Please sign in to comment.