Huge News!Announcing our $40M Series B led by Abstract Ventures.Learn More
Socket
Sign inDemoInstall
Socket

@types/use-persisted-state

Package Overview
Dependencies
Maintainers
1
Versions
5
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

@types/use-persisted-state - npm Package Compare versions

Comparing version 0.3.0 to 0.3.1

7

use-persisted-state/index.d.ts

@@ -6,7 +6,10 @@ // Type definitions for use-persisted-state 0.3

// TypeScript Version: 2.8
import { useState } from 'react';
import { Dispatch, SetStateAction } from 'react';
declare function createPersistedState(key: string, provider?: Pick<Storage, 'getItem' | 'setItem'>): typeof useState;
declare function createPersistedState<S>(key: string, provider?: Pick<Storage, 'getItem' | 'setItem'>): {
(initialState: S | (() => S)): [S, Dispatch<SetStateAction<S>>];
(): [S | undefined, Dispatch<SetStateAction<S | undefined>>];
};
export as namespace createPersistedState;
export default createPersistedState;
{
"name": "@types/use-persisted-state",
"version": "0.3.0",
"version": "0.3.1",
"description": "TypeScript definitions for use-persisted-state",
"homepage": "https://github.com/DefinitelyTyped/DefinitelyTyped/tree/master/types/use-persisted-state",
"license": "MIT",

@@ -14,6 +15,7 @@ "contributors": [

"main": "",
"types": "index",
"types": "index.d.ts",
"repository": {
"type": "git",
"url": "https://github.com/DefinitelyTyped/DefinitelyTyped.git"
"url": "https://github.com/DefinitelyTyped/DefinitelyTyped.git",
"directory": "types/use-persisted-state"
},

@@ -24,4 +26,4 @@ "scripts": {},

},
"typesPublisherContentHash": "fea120729f5b73bf0ea282a4dd522a9b0b5dc48d8adca2a4c6efd4e342e112e2",
"typeScriptVersion": "2.8"
"typesPublisherContentHash": "f064b7129791716453f4dfbb03dc9c6ef7db7c314c6c7145bf6dc5c7f031dfa1",
"typeScriptVersion": "3.8"
}

@@ -5,13 +5,31 @@ # Installation

# Summary
This package contains type definitions for use-persisted-state ( https://github.com/donavon/use-persisted-state#readme ).
This package contains type definitions for use-persisted-state (https://github.com/donavon/use-persisted-state#readme).
# Details
Files were exported from https://github.com/DefinitelyTyped/DefinitelyTyped/tree/master/types/use-persisted-state
Files were exported from https://github.com/DefinitelyTyped/DefinitelyTyped/tree/master/types/use-persisted-state.
## [index.d.ts](https://github.com/DefinitelyTyped/DefinitelyTyped/tree/master/types/use-persisted-state/index.d.ts)
````ts
// Type definitions for use-persisted-state 0.3
// Project: https://github.com/donavon/use-persisted-state#readme
// Definitions by: Karol Majewski <https://github.com/karol-majewski>
// Definitions: https://github.com/DefinitelyTyped/DefinitelyTyped
// TypeScript Version: 2.8
import { Dispatch, SetStateAction } from 'react';
Additional Details
* Last updated: Tue, 12 Feb 2019 23:25:22 GMT
* Dependencies: @types/react
* Global values: createPersistedState
declare function createPersistedState<S>(key: string, provider?: Pick<Storage, 'getItem' | 'setItem'>): {
(initialState: S | (() => S)): [S, Dispatch<SetStateAction<S>>];
(): [S | undefined, Dispatch<SetStateAction<S | undefined>>];
};
export as namespace createPersistedState;
export default createPersistedState;
````
### Additional Details
* Last updated: Sat, 29 Jan 2022 21:31:30 GMT
* Dependencies: [@types/react](https://npmjs.com/package/@types/react)
* Global values: `createPersistedState`
# Credits
These definitions were written by Karol Majewski <https://github.com/karol-majewski>.
These definitions were written by [Karol Majewski](https://github.com/karol-majewski).

Sorry, the diff of this file is not supported yet

SocketSocket SOC 2 Logo

Product

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

Packages

npm

Stay in touch

Get open source security insights delivered straight into your inbox.


  • Terms
  • Privacy
  • Security

Made with ⚡️ by Socket Inc