Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

linter: confusing no-useless-spread #1697

Closed
Boshen opened this issue Dec 16, 2023 · 0 comments · Fixed by #1698
Closed

linter: confusing no-useless-spread #1697

Boshen opened this issue Dec 16, 2023 · 0 comments · Fixed by #1698
Assignees
Labels
A-linter Area - Linter

Comments

@Boshen
Copy link
Member

Boshen commented Dec 16, 2023

I'm testing the https://github.com/getsentry/sentry repo.

with -D no-useless-spread:

    ╭─[static/app/views/performance/database/useAvailableDurationAggregates.tsx:15:1]
 15 │   if (organization.features?.includes('performance-database-view-percentiles')) {
 16 │     availableAggregates.push(...['p50', 'p75', 'p95', 'p99']);
    ·                              ───
 17 │   }
    ╰────
  help: Consider removing the spread operator.

Removing the spread operator is obviously wrong, how can we improve this 🤔

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
A-linter Area - Linter
Projects
None yet
Development

Successfully merging a pull request may close this issue.

2 participants