mirror of
https://github.com/ionic-team/ionic-framework.git
synced 2025-08-19 03:32:21 +08:00
fix(react): IonTabButton will call custom onClick handlers (#25313)
Resolves #22511
This commit is contained in:
@ -34,6 +34,11 @@ export const IonTabButton = /*@__PURE__*/ (() =>
|
||||
}
|
||||
|
||||
render() {
|
||||
/**
|
||||
* onClick is excluded from the props, since it has a custom
|
||||
* implementation within IonTabBar.tsx. Calling onClick within this
|
||||
* component would result in duplicate handler calls.
|
||||
*/
|
||||
const { onClick, ...rest } = this.props;
|
||||
return (
|
||||
<IonTabButtonInner
|
||||
|
Reference in New Issue
Block a user