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

149
Views
Remove cookie/local storage on browser close, but not page refresh or new tab

In my React app, I am looking to use either a Cookie/Local storage for some state. So I want

  1. Cookie/Local storage to be set on initial load (based on state from server)
  2. Cookie/Local storage should be retained on page refresh/new tab
  3. Cookie/Local storage should be cleared on browser close

Also, I would prefer a React dependency for either cookie/local storage solution.

about 4 years ago · Juan Pablo Isaza
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!