Business
Jobs
  • About Us
  • Solutions
    • Job Postings
      Post your job and receive qualified candidates in 48h.
    • Candidate Assessments
      500+ technical and psychological tests, plus anti-fraud.
    • Headhunting
      Tailor-made executive search from start to finish.
    • Payroll + EOR
      Payroll dispersal and EOR across 15+ LATAM countries.
  • Pricing
  • Jobs

0

349
Views
how to resolve TS warning of unused destructured values in a object. only rest/spread values is being used

I often have to destructure JS objects and only use the rest/spread part. Typescript then shows the error of the unused variable.

For example, in the attached screenshot, you can see that while destructuring cart, I have a use-case where products is not being used while all other keys/members are being used.

TS warning is genuine so is there any way to resolve this warning of no unused vars.

enter image description here

about 4 years ago · Santiago Gelvez
Answer question
Find remote jobs

Discover the new way to find a job!

Top jobs
Top job categories
Business
Post vacancy Pricing Sales
Legal
Terms and conditions Privacy policy
© 2026 PeakU Inc. All Rights Reserved.
Andres GPT
Show me some job opportunities
There's an error!