Skip to content

Conversation

@scttcper
Copy link
Member

a lot of these were really similar GenericPerformanceWidgetProps components

part of https://github.com/getsentry/frontend-tsc/issues/79

a lot of these were really similar GenericPerformanceWidgetProps components

part of getsentry/frontend-tsc#79
@scttcper scttcper requested review from a team October 17, 2024 19:03
@github-actions github-actions bot added the Scope: Frontend Automatically applied to PRs that change frontend components label Oct 17, 2024
Comment on lines +755 to +756
const Visualizations: GenericPerformanceWidgetProps<DataType>['Visualizations'] =
organization.features.includes('performance-new-widget-designs')
Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

lots of the changes in this pr should be just the whitespace changes

[PerformanceWidgetSetting.SLOW_SCREENS_BY_WARM_START]:
'count_starts(measurements.app_start_warm)',
} as any
)[props.chartSetting];
Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

can't cast this to keyof itself

<StackedAreaChart
{...provided.widgetData.chart}
{...provided}
{...(provided as any)}
Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

the types here don't totally line up and it was previously any

Copy link
Member

@gggritso gggritso left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

👍🏻

Comment on lines +644 to +648
const description = listItem[SpanMetricsField.SPAN_DESCRIPTION] as string;
const group = listItem[SpanMetricsField.SPAN_GROUP] as string;
const projectID = listItem['project.id'] as number;
const timeSpentPercentage = listItem[fieldString] as number;
const totalTime = listItem[`sum(${SpanMetricsField.SPAN_SELF_TIME})`] as number;
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Out of curiosity, why the change to as here?

Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

before the type was
const totalTime: number = any which was fine. But now it's const totalTime = string | number so it has to be casted to number. I could've left the const totalTime: number i guess

Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

K, just curious!

@scttcper scttcper merged commit 90e760b into master Oct 18, 2024
43 of 44 checks passed
@scttcper scttcper deleted the scttcper/implicit-widget-cards branch October 18, 2024 20:45
jan-auer added a commit that referenced this pull request Oct 21, 2024
* master: (288 commits)
  feat(metrics): Register MRI for spans/count_per_root_project (#78992)
  feat(dynamic-sampling): Settings for sample rate (#79341)
  Revert "feat(sentry-sdk): Enable HTTP2 transport" (#79391)
  fix(feedback): keep oldest date_added for duplicate user reports (#79387)
  chore(issue-stream): Remove tooltip for Unhandled (#79385)
  chore(autofix): Show banner if gen AI consent is given, even if no feature flag (#79362)
  chore(autofix+copilot) Allow autofix without FF if gen AI consent given (#79361)
  Fixes VULN-50 by enforcing option (#79384)
  perf(issues): improve adjacent_events query (#79365)
  feat(issues): Add anchor links back to issue sections (#79333)
  fix(issue-views): Make tab bar take up entire row (#79383)
  chore(issues): Add additional metrics for ownership matching (#79302)
  feat(insights): create screen rendering module (#79192)
  fix(issues): Avoid streamline issue layout rerenders (#79327)
  ref(performance): Add missing types to performance widgets (#79301)
  chore(issue-views): Add translation wrapper to aria label (#79320)
  chore(issue-stream): Reduce font size of title and message (#79378)
  feat(insights): update headers and breadcrumbs on frontend domain view (#78945)
  feat(insights): add view trends button to ai overview (#78611)
  ref(rr6): Remove unused param (#79379)
  ...
@github-actions github-actions bot locked and limited conversation to collaborators Nov 3, 2024
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.

Labels

Scope: Frontend Automatically applied to PRs that change frontend components

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants