Skip to content

Commit

Permalink
Fixes #280, #261 and languages
Browse files Browse the repository at this point in the history
  • Loading branch information
jamesbayly committed Feb 19, 2023
1 parent 3a89ff4 commit a5d56c0
Show file tree
Hide file tree
Showing 7 changed files with 105 additions and 62 deletions.
132 changes: 80 additions & 52 deletions docs/.vuepress/config.ts
Original file line number Diff line number Diff line change
Expand Up @@ -86,89 +86,101 @@ export default defineUserConfig({
description:
"Explore and transform your chain data to build intuitive dApps faster!",
},
"/zh/": {
lang: "zh-CN",
title: "SubQuery Academy (Documentation)",
description:
"Explore and transform your chain data to build intuitive dApps faster!.",
},
"/es/": {
lang: "es",
title: "SubQuery Academy (Documentation)",
description:
"Explore and transform your chain data to build intuitive dApps faster!.",
},
"/de/": {
lang: "de",
title: "SubQuery Academy (Documentation)",
description:
"Explore and transform your chain data to build intuitive dApps faster!.",
},
// "/id/": {
// lang: "id",
// title: "SubQuery Academy (Documentation)",
// description:
// "Explore and transform your chain data to build intuitive dApps faster!.",
// },
"/id/": {
lang: "id",
title: "SubQuery Academy (Documentation)",
description:
"Explore and transform your chain data to build intuitive dApps faster!.",
},
"/it/": {
lang: "it",
title: "SubQuery Academy (Documentation)",
description:
"Explore and transform your chain data to build intuitive dApps faster!.",
},
"/ja/": {
lang: "ja",
title: "SubQuery Academy (Documentation)",
description:
"Explore and transform your chain data to build intuitive dApps faster!.",
},
"/ko/": {
lang: "ko",
title: "SubQuery Academy (Documentation)",
description:
"Explore and transform your chain data to build intuitive dApps faster!.",
},
"/ru/": {
lang: "ru",
title: "SubQuery Academy (Documentation)",
description:
"Explore and transform your chain data to build intuitive dApps faster!.",
},
// "/th/": {
// lang: "th",
// title: "SubQuery Academy (Documentation)",
// description:
// "Explore and transform your chain data to build intuitive dApps faster!.",
// },
// "/tr/": {
// lang: "tr",
// title: "SubQuery Academy (Documentation)",
// description:
// "Explore and transform your chain data to build intuitive dApps faster!.",
// },
"/uk/": {
lang: "uk",
"/th/": {
lang: "th",
title: "SubQuery Academy (Documentation)",
description:
"Explore and transform your chain data to build intuitive dApps faster!.",
},
"/vi/": {
lang: "vi",
"/tr/": {
lang: "tr",
title: "SubQuery Academy (Documentation)",
description:
"Explore and transform your chain data to build intuitive dApps faster!.",
},
"/zh/": {
lang: "zh-CN",
"/uk/": {
lang: "uk",
title: "SubQuery Academy (Documentation)",
description:
"Explore and transform your chain data to build intuitive dApps faster!.",
},
"/vi/": {
lang: "vi",
title: "SubQuery Academy (Documentation)",
description:
"Explore and transform your chain data to build intuitive dApps faster!.",
},
/*
"/es/": {
lang: "es",
title: "SubQuery Academy (Documentation)",
description:
"Explore and transform your chain data to build intuitive dApps faster!.",
},
*/
/*
"/it/": {
lang: "it",
title: "SubQuery Academy (Documentation)",
description:
"Explore and transform your chain data to build intuitive dApps faster!.",
},
"/ja/": {
lang: "ja",
title: "SubQuery Academy (Documentation)",
description:
"Explore and transform your chain data to build intuitive dApps faster!.",
},
"/ko/": {
lang: "ko",
title: "SubQuery Academy (Documentation)",
description:
"Explore and transform your chain data to build intuitive dApps faster!.",
},
*/
},
theme: defaultTheme({
lastUpdated: true,
locales: {
"/": {
sidebar: getSidebar(""),
},
"/de/": {
selectLanguageName: "German",
sidebar: getSidebar("/de"),
},
"/id/": {
selectLanguageName: "Indoneisan",
sidebar: getSidebar("/id"),
},
"/th/": {
selectLanguageName: "Thai",
sidebar: getSidebar("/th"),
},
"/tr/": {
selectLanguageName: "Turkish",
sidebar: getSidebar("/tr"),
},
"/zh/": {
selectLanguageName: "Chinese",
sidebar: getSidebar("/zh"),
Expand All @@ -185,6 +197,22 @@ export default defineUserConfig({
selectLanguageName: "Ukranian",
sidebar: getSidebar("/uk"),
},
"/es/": {
selectLanguageName: "Espanol",
sidebar: getSidebar("/es"),
},
"/it/": {
selectLanguageName: "Italian",
sidebar: getSidebar("/it"),
},
"/ja/": {
selectLanguageName: "Japanese",
sidebar: getSidebar("/js"),
},
"/ko/": {
selectLanguageName: "Korean",
sidebar: getSidebar("/ko"),
},
},
logo: "/assets/img/logo.png",
navbar: [
Expand Down
10 changes: 5 additions & 5 deletions docs/build/graph-migration.md
Original file line number Diff line number Diff line change
Expand Up @@ -33,7 +33,7 @@ Notable differences include:

## Manifest File

The manifest file contains the largest set of differences, but once you understand those they can be easily overcome. Most of these changes are due to the layout of this file, you can see the [full documentation of this file here](./manifest.md).
The manifest file contains the largest set of differences, but once you understand those they can be easily overcome. Most of these changes are due to the layout of this file, you can see the [full documentation of this file here](./manifest/avalanche.md).

**Notable differences include:**

Expand All @@ -55,7 +55,7 @@ The manifest file contains the largest set of differences, but once you understa
- Instead of listing the blocks/events/calls as the key and then denoting the handler that processes it. In SubQuery, you define the handler as the key and then what follows is the description of how this handler is triggered.

- In a SubQuery project, you can document both block handlers, call handlers, and event handlers in the same `mapping:` object, the `kind:` property notes what type we are using.
- SubQuery supports advanced filtering on the handler. The format of the supported filter varies amongst block/events/calls/transactions, and between the different blockchain networks. You should refer to the [documentation for a detailed description of each filter](./manifest.md#mapping-handlers-and-filters).
- SubQuery supports advanced filtering on the handler. The format of the supported filter varies amongst block/events/calls/transactions, and between the different blockchain networks. You should refer to the [documentation for a detailed description of each filter](./manifest/avalanche.md#mapping-handlers-and-filters).

![Difference between a SubGraph and a SubQuery project](/assets/img/subgraph-manifest-3.png)

Expand Down Expand Up @@ -250,13 +250,13 @@ The above example assumes that the user has an ABI file named `erc20.json`, so t

Now that you have a clear understanding of how to build a basic SubQuery project, what are the next steps of your journey?

Now, you can easily publish your project. SubQuery provides a free Managed Service where you can deploy your new project. You can deploy it to [SubQuery Managed Service](https://managedservice.subquery.network) and query it using our [Explorer](https://explorer.subquery.network). Read this complete guide on how to [publish your new project to SubQuery Projects](../../run_publish/publish.md).
Now, you can easily publish your project. SubQuery provides a free Managed Service where you can deploy your new project. You can deploy it to [SubQuery Managed Service](https://managedservice.subquery.network) and query it using our [Explorer](https://explorer.subquery.network). Read this complete guide on how to [publish your new project to SubQuery Projects](../run_publish/publish.md).

To dive deeper into the developer documentation, jump to the [Build ](../../build/introduction.md) section and learn more about the three key files: **the manifest file, the GraphQL schema, and the mappings file.**
To dive deeper into the developer documentation, jump to the [Build ](../build/introduction.md) section and learn more about the three key files: **the manifest file, the GraphQL schema, and the mappings file.**

If you want to practice with more real examples, then head to our [Courses](../academy/academy.md) section and learn important concepts with related exercises and lab workbooks. Get access to readily available and open-source projects, and get a hands-on experience with SubQuery projects.

In the end, if you want to explore more ways to run and publish your project, refer to [Run & Publish section](../../run_publish/run.md). Get complete information about all the ways to run your SubQuery project, along with advanced GraphQL aggregation and subscription features.
In the end, if you want to explore more ways to run and publish your project, refer to [Run & Publish section](../run_publish/run.md). Get complete information about all the ways to run your SubQuery project, along with advanced GraphQL aggregation and subscription features.

## Summary

Expand Down
11 changes: 11 additions & 0 deletions docs/build/manifest/cosmos.md
Original file line number Diff line number Diff line change
Expand Up @@ -253,6 +253,17 @@ network:
bypassBlocks: [1, 2, 3, "105-200", 290]
```

::: tip Indexing chains that have skipped blocks
Some Cosmos chains, like Juno, have hard forks that intentionally skip blocks. To handle this situation, you should use the bypass blocks feature and connect to different RPC endpoints as required. For example, on Juno, block 2578098 represents a hard fork, if you want to index data before this block:

1. Find a RPC endpoint that provides archival data for blocks before 2578098
2. Set bypass blocks to `bypassBlocks: []`
3. Index data up to block 2578098, you'll notice SubQuery will stop there because most RPC endpoints only have one set of data
4. Without clearing the database, change the RPC endpoint to a new endpoint that has blocks after 2578098
5. Continue indexing

:::

## Validating

You can validate your project manifest by running `subql validate`. This will check that it has the correct structure, valid values where possible and provide useful feedback as to where any fixes should be made.
4 changes: 2 additions & 2 deletions docs/quickstart/quickstart_chains/polkadot-humanode.md
Original file line number Diff line number Diff line change
@@ -1,8 +1,8 @@
# Polkadot Quick Start (Humanode)
# Polkadot/Substrate Quick Start (Humanode)

## Goals

This quick guide aims to adapt the standard starter project and index all transfers, bioauthenitcation events, and online validator nodes from Humanode chain.
This quick guide aims to adapt the standard starter project and index all transfers, bioauthenitcation events, and online validator nodes from Humanode chain. Humanode is a standalone Substrate chain, but the same process applies to is as a normal Polkadot parachain or relaychain.

::: warning Important
Before we begin, ensure that you have initialized your project using the steps in the [Start Here](../quickstart.md) section.
Expand Down
2 changes: 1 addition & 1 deletion docs/quickstart/quickstart_chains/polkadot.md
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
# Polkadot Quick Start
# Polkadot/Substrate Quick Start

## Goals

Expand Down
4 changes: 2 additions & 2 deletions docs/quickstart/whats-next.md
Original file line number Diff line number Diff line change
Expand Up @@ -4,10 +4,10 @@ Now that you have a clear understanding of how to build a basic SubQuery project

- Now, you can easily publish your project. SubQuery provides a managed service solution where you can deploy your new project. You can deploy it to [SubQuery Managed Service](https://managedservice.subquery.network) and query it using our [Explorer](https://explorer.subquery.network). Read this complete guide on how to [publish your new project to SubQuery Projects](../run_publish/publish.md).

- To dive deeper into the developer documentation, jump to the [Build ](../../build/introduction.md) section and learn more about the three key files: **the manifest file, the GraphQL schema, and the mappings file.**
- To dive deeper into the developer documentation, jump to the [Build ](../build/introduction.md) section and learn more about the three key files: **the manifest file, the GraphQL schema, and the mappings file.**

- If you want to practice with more real examples, then head to our [Courses](../academy/herocourse/welcome.md) section and learn important concepts with related exercises and lab workbooks. Get access to readily available and open-source projects, and get a hands-on experience with SubQuery projects.

- Find out **how to build a performant SubQuery project and avoid common mistakes** in [Project Optimisation](../build/optimisation.md).

- In the end, if you want to explore more ways to run and publish your project, refer to [Run & Publish section](../../run_publish/run.md). Get complete information about all the ways to run your SubQuery project, along with advanced GraphQL aggregation and subscription features.
- In the end, if you want to explore more ways to run and publish your project, refer to [Run & Publish section](../run_publish/run.md). Get complete information about all the ways to run your SubQuery project, along with advanced GraphQL aggregation and subscription features.
4 changes: 4 additions & 0 deletions docs/run_publish/subscription.md
Original file line number Diff line number Diff line change
Expand Up @@ -71,6 +71,10 @@ Note that the `mutation` filter can be one of `INSERT`, `UPDATE` or `DELETE`.
Please note that you must enable the `--subscription` flag on both the node and query service in order to use these functions.
:::

## Using in the Managed Service

The managed service supports subscriptions for paid plans, you must enable subscription support whend deploying your project in our service under "Advanced Settings"

::: warning Important
The subcription feature works on SubQuery's Managed Service when you directly call the listed GraphQL endpoint. It will not work within the in-browser GraphQL playground.
:::

0 comments on commit a5d56c0

Please sign in to comment.