docs(ui-kit/react): reconcile contradictory plugin precedence (ENG-37996) - #463
Open
raj-dubey1 wants to merge 1 commit into
Open
docs(ui-kit/react): reconcile contradictory plugin precedence (ENG-37996)#463raj-dubey1 wants to merge 1 commit into
raj-dubey1 wants to merge 1 commit into
Conversation
…996) The v7 plugin docs contradicted each other on whether custom plugins override built-in ones. overview.mdx and custom-plugin.mdx claimed custom plugins are "appended after the defaults" so "default plugins keep priority", while text-formatters.mdx claimed they are "prepended before the defaults" and take precedence. Verified against the shipped @cometchat/chat-uikit-react v7.1.0 source: - CometChatProvider builds `[...plugins, ...defaultPlugins]` (user plugins first) - CometChatPluginRegistry resolves with `.find()` (first match wins) So custom plugins ARE prepended and DO take precedence — text-formatters.mdx was correct. Fix overview.mdx and custom-plugin.mdx to match, and add a note that precedence is by plugin order + messageTypes/messageCategories, not `id`. Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
|
Preview deployment for your docs. Learn more about Mintlify Previews.
💡 Tip: Enable Workflows to automatically generate PRs for you. |
PrajwalDhuleCC
approved these changes
Aug 7, 2026
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
What & why
Fixes ENG-37996 — the React UI Kit v7 plugin docs contradicted each other on whether a custom plugin overrides a built-in one:
ui-kit/react/plugins/overview.mdxui-kit/react/plugins/custom-plugin.mdxui-kit/react/plugins/text-formatters.mdxTwo pages said defaults win; one said the custom plugin wins. Since resolution is explicitly "first match wins", they can't all be true.
Ground truth (verified against the shipped package)
Confirmed against
@cometchat/chat-uikit-reactv7.1.0 (npm tarball), not inference:CometChatProviderbuilds the registry as[...plugins, ...defaultPlugins]— user-suppliedpluginscome first, defaults after (dist/index.js:6099).CometChatPluginRegistryresolves a message with.find(...)— first match wins, scanning from index 0 (dist/index.js:350).So custom plugins are prepended and do take precedence.
text-formatters.mdxwas the correct page;overview.mdxandcustom-plugin.mdxwere wrong.Changes
overview.mdx— "Adding Plugins" now says custom plugins are prepended and take priority (enabling override of a built-in by declaring the samemessageTypes/messageCategories); added a resolution note that precedence is by plugin order +messageTypes/messageCategories, notid.custom-plugin.mdx— Step 2 explanation corrected to "prepended before the defaults", with a note on how to override a built-in type.text-formatters.mdx— already correct; added a missing trailing period only.Scope / notes
idclarification. The remaining ticket recommendations (index the v7 source into the KB, boost v7 doc ranking, update the validation critic's ground-truth) are AI-knowledge-base tasks, not docs edits, and are out of scope for this PR.🤖 Generated with Claude Code