Socket
Socket
Sign inDemoInstall

react-apollo-idle-cache-eviction

Package Overview
Dependencies
37
Maintainers
1
Versions
2
Alerts
File Explorer

Advanced tools

Install Socket

Detect and block malicious and high-risk dependencies

Install

    react-apollo-idle-cache-eviction

Hooks for performing cache eviction when the user is detected to be idle.


Version published
Maintainers
1
Install size
14.7 kB
Created

Readme

Source

react-apollo-idle-cache-eviction

Hooks for performing cache eviction when the user is detected to be idle.

NPM

Install

npm install --save react-apollo-idle-cache-eviction

Usage

import React, { Component } from 'react'

import { useIdleCacheEviction } from 'react-apollo-idle-cache-eviction'

const AppRoot = () => {
  useIdleCacheEviction({
    checkInterval: 10 * 1000,
    minimumIdleMs: 30 * 1000,
    onCacheClear: () => console.log("Cleared!")
  });

  return (
    <div>This is a page.</div>
  )
}

License

MIT © Senney

FAQs

Last updated on 03 Jun 2020

Did you know?

Socket for GitHub automatically highlights issues in each pull request and monitors the health of all your open source dependencies. Discover the contents of your packages and block harmful activity before you install or update your dependencies.

Install

Related posts

SocketSocket SOC 2 Logo

Product

  • Package Alerts
  • Integrations
  • Docs
  • Pricing
  • FAQ
  • Roadmap

Stay in touch

Get open source security insights delivered straight into your inbox.


  • Terms
  • Privacy
  • Security

Made with ⚡️ by Socket Inc