use-object

1.0.2 • Public • Published

NPM

use-object

A custom React hook that lets you manipulate an array data structure without ever needing extra utilities.

👉 Demo site and docs.

Start with:

npm install --save use-object

Then, import and use the hook:

import useMap from 'use-object'
// …in your functional component:
  const [ map, { get, set, update, getIn, remove, replace } ] = useMap(initialMap);

Docs

The complete documentation as well as a live demo is available here.

License

MIT © filipdanic

Related

If you like use-object you might find use-array useful as well.

/use-object/

    Package Sidebar

    Install

    npm i use-object

    Weekly Downloads

    2

    Version

    1.0.2

    License

    MIT

    Unpacked Size

    16.5 kB

    Total Files

    7

    Last publish

    Collaborators

    • filipdanic