Socket
Book a DemoInstallSign in
Socket

@ahooksjs/use-url-state

Package Overview
Dependencies
Maintainers
5
Versions
68
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

@ahooksjs/use-url-state

A hook that stores the state into url query parameters.

latest
Source
npmnpm
Version
3.5.1
Version published
Weekly downloads
13K
1.84%
Maintainers
5
Weekly downloads
 
Created
Source

useUrlState

A hook that stores the state into url query parameters.

Installing

Inside your React project directory, run the following:

yarn add @ahooksjs/use-url-state -S

Or with npm:

npm install @ahooksjs/use-url-state -S

Or with pnpm

pnpm add @ahooksjs/use-url-state

Example

import useUrlState from '@ahooksjs/use-url-state';

const [state, setState] = useUrlState({ demoCount: '1' });

Documentation

https://ahooks.js.org/hooks/state/use-url-state

FAQs

Package last updated on 27 Dec 2022

Did you know?

Socket

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