bito-code-review[bot] commented on code in PR #41492:
URL: https://github.com/apache/superset/pull/41492#discussion_r3732754715
##########
superset-frontend/packages/superset-ui-core/src/components/AsyncAceEditor/index.tsx:
##########
@@ -57,6 +57,9 @@ export interface AceCompleterKeywordData {
meta: string;
docText?: string;
docHTML?: string;
+ // The label Ace displays in the autocomplete popup and passes back to
+ // `insertMatch`; may differ from `value`, the text actually inserted.
+ caption?: string;
Review Comment:
<div>
<div id="suggestion">
<div id="issue"><b>Duplicate interface definitions in same module</b></div>
<div id="fix">
The `AceCompleterKeywordData` interface (lines 53-63) is semantically
duplicated in `types.ts` (lines 25-35) with identical structure and the same
`caption` property. Having the same interface in two files creates maintenance
risk — a future update to one file may not propagate to the other. Since
`AsyncAceEditor.stories.tsx` and `AsyncAceEditor.test.tsx` already import from
`./types`, that file is the canonical source. Consider consolidating: define
interfaces only in types.ts and re-export from index.tsx if needed.
</div>
</div>
<small><i>Code Review Run #4ee74e</i></small>
</div>
---
Should Bito avoid suggestions like this for future reviews? (<a
href=https://alpha.bito.ai/home/ai-agents/review-rules>Manage Rules</a>)
- [ ] Yes, avoid them
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: [email protected]
For queries about this service, please contact Infrastructure at:
[email protected]
---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]