File tree Expand file tree Collapse file tree 3 files changed +3
-13
lines changed Expand file tree Collapse file tree 3 files changed +3
-13
lines changed Original file line number Diff line number Diff line change 33## Unreleased
44
55- "You miss 100 percent of the chances you don't take. — Wayne Gretzky" — Michael Scott
6+ - [ react] feat: Add @sentry/react package (#2631 )
67
78## 5.16.0
89
Original file line number Diff line number Diff line change @@ -66,7 +66,6 @@ interface ProfilerProps {
6666
6767class Profiler extends React . Component < ProfilerProps > {
6868 public activity : number | null ;
69-
7069 public constructor ( props : ProfilerProps ) {
7170 super ( props ) ;
7271
@@ -101,14 +100,11 @@ class Profiler extends React.Component<ProfilerProps> {
101100 }
102101}
103102
104- function withProfiler < P extends object > (
105- WrappedComponent : React . ComponentType < P > ,
106- profilerProps ?: ProfilerProps ,
107- ) : React . FC < P > {
103+ function withProfiler < P extends object > ( WrappedComponent : React . ComponentType < P > ) : React . FC < P > {
108104 const componentDisplayName = WrappedComponent . displayName || WrappedComponent . name || UNKNOWN_COMPONENT ;
109105
110106 const Wrapped : React . FC < P > = ( props : P ) => (
111- < Profiler componentDisplayName = { componentDisplayName } { ... profilerProps } >
107+ < Profiler componentDisplayName = { componentDisplayName } >
112108 < WrappedComponent { ...props } />
113109 </ Profiler >
114110 ) ;
Original file line number Diff line number Diff line change @@ -66,13 +66,6 @@ describe('withProfiler', () => {
6666 op : 'react' ,
6767 } ) ;
6868 } ) ;
69-
70- it ( 'is called with a custom displayName' , ( ) => {
71- const ProfiledComponent = withProfiler ( ( ) => < h1 > Hello World</ h1 > , { componentDisplayName : 'Test' } ) ;
72-
73- create ( < ProfiledComponent /> ) ;
74- expect ( mockPushActivity ) . toHaveBeenLastCalledWith ( 'Test' , expect . objectContaining ( { description : '<Test>' } ) ) ;
75- } ) ;
7669 } ) ;
7770 } ) ;
7871} ) ;
You can’t perform that action at this time.
0 commit comments