From d7ee919f951be00c431cbcadab92ca4ba79b3c11 Mon Sep 17 00:00:00 2001 From: asyncapi-bot Date: Mon, 28 Oct 2024 15:46:11 +0100 Subject: [PATCH] docs(generator): update latest generator documentation (#3339) --- markdown/docs/tools/generator/asyncapi-document.md | 2 +- markdown/docs/tools/generator/hooks.md | 6 +++--- 2 files changed, 4 insertions(+), 4 deletions(-) diff --git a/markdown/docs/tools/generator/asyncapi-document.md b/markdown/docs/tools/generator/asyncapi-document.md index b6a3607b066..dfd2db6e854 100644 --- a/markdown/docs/tools/generator/asyncapi-document.md +++ b/markdown/docs/tools/generator/asyncapi-document.md @@ -41,7 +41,7 @@ graph LR The AsyncAPI document's content is accessible to you while writing your template in two distinct ways: - The `originalAsyncAPI`, which is a stringified version of the AsyncAPI document provided as input, without any modifications. -- The `asyncapi` (`AsyncAPIDocument`) which is an object with a set of helper functions, that comes as a result of the `Parser` manipulating the `originalAsyncAPI` .The `asyncapi` functions make it easier to access the contents of AsyncAPI documents in your templates. +- The `asyncapi` (`AsyncAPIDocument`) which is an object with a set of helper functions, that comes as a result of the `Parser` manipulating the `originalAyncAPI` .The `asyncapi` functions make it easier to access the contents of AsyncAPI documents in your templates. In the following sections, you will learn how to use either the **originalAsyncAPI** or the **asyncapi** in your template. diff --git a/markdown/docs/tools/generator/hooks.md b/markdown/docs/tools/generator/hooks.md index d2c06ddc0c4..cf1cb1dbc20 100644 --- a/markdown/docs/tools/generator/hooks.md +++ b/markdown/docs/tools/generator/hooks.md @@ -8,9 +8,9 @@ The following types of hooks are currently supported: |Hook type|Description| Return type | Arguments |---|---|---|---| -| `generate:before` | Called after registration of all filters and before the generator starts processing of the template. | void : Nothing is expected to be returned. | [The generator instance](https://github.com/asyncapi/generator/blob/master/docs/api.md) -| `generate:after` | Called at the very end of the generation. | void : Nothing is expected to be returned. | [The generator instance](https://github.com/asyncapi/generator/blob/master/docs/api.md) -| `setFileTemplateName ` | Called right before saving a new file generated by [file template](./file-templates.md). | string : a new filename for the generator to use for the file template. | [The generator instance](https://github.com/asyncapi/generator/blob/master/docs/api.md) and object in the form of `{ "originalFilename" : string }` +| `generate:before` | Called after registration of all filters and before the generator starts processing of the template. | void : Nothing is expected to be returned. | [The generator instance](/api) +| `generate:after` | Called at the very end of the generation. | void : Nothing is expected to be returned. | [The generator instance](/api) +| `setFileTemplateName ` | Called right before saving a new file generated by [file template](./file-templates.md). | string : a new filename for the generator to use for the file template. | [The generator instance](/api) and object in the form of `{ "originalFilename" : string }` The generator parses: - All the files in the `.hooks` directory inside the template.