Skip to content

Commit

Permalink
Remove defaultProps from BreakableText
Browse files Browse the repository at this point in the history
Signed-off-by: cs-308-2023 <[email protected]>
  • Loading branch information
ADI-ROXX committed Jan 23, 2025
1 parent b7578bc commit 05ae011
Showing 1 changed file with 1 addition and 7 deletions.
8 changes: 1 addition & 7 deletions packages/jaeger-ui/src/components/common/BreakableText.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -24,8 +24,7 @@ type Props = {
wordRegexp?: RegExp;
};

export default function BreakableText(props: Props) {
const { className, text, wordRegexp = WORD_RX } = props;
export default function BreakableText({ className = 'BreakableText', text, wordRegexp = WORD_RX }: Props) {
if (!text) {
return typeof text === 'string' ? text : null;
}
Expand All @@ -43,8 +42,3 @@ export default function BreakableText(props: Props) {
}
return spans;
}

BreakableText.defaultProps = {
className: 'BreakableText',
wordRegexp: WORD_RX,
};

0 comments on commit 05ae011

Please sign in to comment.