Skip to content

Latest commit

 

History

History
 
 

swr-devtools-panel

Folders and files

NameName
Last commit message
Last commit date

parent directory

..
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

swr-devtools-panel

npm version

This package is a React component of SWR Devtools panel. If you want to use this component as a React component, you can place it on your own.

This package hasn't been stable yet, so its interface would be changed in the future releases.

Install

// install peerDependencies
$ yarn add react swr styled-components
$ yarn add swr-devtools-panel

How to use

import { useSWRConfig } from "swr";
import { SWRDevToolsPanel } from "swr-devtools-panel";

const App = () => {
  const { cache } = useSWRConfig();
  return (
    <SWRDevToolsPanel cache={cache}>
      <Page />
    </SWRDevToolsPanel>
  );
}

LICENSE

MIT