Skip to content

Conversation

@AceTheCreator
Copy link
Member

@AceTheCreator AceTheCreator commented Nov 12, 2025

This PR introduces a plugin system for the AsyncAPI React component, enabling developers to extend and customize the documentation renderer with custom components, event handling, and dynamic plugin management.

Changes

  • New AsyncApiPlugin interface and PluginAPI for plugin development
  • Component registration in PluginSlot.OPERATION slots
  • Event system: on(), off(), emit() for inter-plugin communication
  • Dynamic plugin registration/unregistration at runtime
  • Priority-based component ordering (higher priority renders first)
  • Full TypeScript support
const plugin: AsyncApiPlugin = {
  name: 'my-plugin',
  version: '1.0.0',
  install(api: PluginAPI) {
    api.registerComponent(PluginSlot.OPERATION, MyComponent, { priority: 150 });
    api.on('event-name', (data) => console.log(data));
  }
};

<AsyncApi schema={schema} plugins={[plugin]} />

Fixes #914

Breaking Changes

None

@fmvilas
Copy link
Member

fmvilas commented Nov 12, 2025

Just a heads up that your PR description has "Fixes" as a title, preventing the issue from being closed automatically when this PR is merged. It should follow the GitHub convention of "Fixes #914" or "Closes #914" or "Resolves #914".

@sonarqubecloud
Copy link

sonarqubecloud bot commented Dec 3, 2025

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Execute API calls from UI

2 participants