
Security News
Insecure Agents Podcast: Certified Patches, Supply Chain Security, and AI Agents
Socket CEO Feross Aboukhadijeh joins Insecure Agents to discuss CVE remediation and why supply chain attacks require a different security approach.
@asyncapi/generator-hooks
Advanced tools
Library with hooks function for templates using AsyncAPI Generator
This is a library with generator hooks that are used in more than one template. Use these hooks to not double your work. Read Generator documentation to understand how to configure your template to use external hooks.
This library consists of the following hooks:
| Hook name | Hook type | Description |
|---|---|---|
createAsyncapiFile | generate:after | It creates AsyncAPI file with content of the spec file passed to the generator. By default it created the file in the root of the generation output directory. This hook also supports custom parameters that user can pass to template generation. Parameter called asyncapiFileDir allows user to specify the location where spec file should be created. To make your template users use this parameter, you need to add it to the configuration of your template like other parameters |
@asyncapi/generator-hooks to dependencies of your template
npm install @asyncapi/generator-hooks --save
{
"hooks": {
"@asyncapi/generator-hooks": "createAsyncapiFile"
}
}
{
"parameters": {
"asyncapiFileDir": {
"description": "Custom location of the AsyncAPI file that you provided as an input in generation. By default it is located in the root of the output directory",
"required": false
}
},
"hooks": {
"@asyncapi/generator-hooks": "createAsyncapiFile"
}
}
FAQs
Library with hooks function for templates using AsyncAPI Generator
The npm package @asyncapi/generator-hooks receives a total of 24,394 weekly downloads. As such, @asyncapi/generator-hooks popularity was classified as popular.
We found that @asyncapi/generator-hooks demonstrated a not healthy version release cadence and project activity because the last version was released a year ago. It has 3 open source maintainers collaborating on the project.
Did you know?

Socket for GitHub automatically highlights issues in each pull request and monitors the health of all your open source dependencies. Discover the contents of your packages and block harmful activity before you install or update your dependencies.

Security News
Socket CEO Feross Aboukhadijeh joins Insecure Agents to discuss CVE remediation and why supply chain attacks require a different security approach.

Security News
Tailwind Labs laid off 75% of its engineering team after revenue dropped 80%, as LLMs redirect traffic away from documentation where developers discover paid products.

Security News
The planned feature introduces a review step before releases go live, following the Shai-Hulud attacks and a rocky migration off classic tokens that disrupted maintainer workflows.