2.8.3 • Published 2 months ago

hookings v2.8.3

Weekly downloads
-
License
MIT
Repository
github
Last release
2 months ago

Installation 🚀

You can install hookings using npm:

npm install hookings

or

yarn add hookings

Features 🌟

  • Easy-to-use and well-documented hooks for common React use-cases.
  • Highly customizable options to adapt the hooks to your needs.
  • A growing collection of useful and versatile hooks.

Available Hooks 🎣

  1. useBoolean: A hook to manage a boolean state and provide functions to toggle it.
  2. useKeyDown: A hook to capture the event of pressing a specific keyboard key with customizable options for modifier keys.
  3. useDebounce: A hook to create a debounce effect that delays the execution of a function until a certain amount of time has passed without additional calls.
  4. useInterval: A hook to execute a function repeatedly at regular intervals.
  5. useDropdown: A hook to handle the behavior of a dropdown menu and detect clicks outside of the dropdown to close it.
  6. useAsync: A hook to simplify the management of asynchronous operations, handling loading, error, and result states.

Note: More hooks are in development and will be added to the collection soon! 🚧

Usage 📝

useKeyDown

Here's a quick example of how to use the useKeyDown hook:

import { useKeyDown } from "hookings";

const MyComponent = () => {
  // Call this function when the 'Ctrl + Enter' keys are pressed
  const handleKeyPress = () => {
    // Your logic here...
  };

  useKeyDown("KeyEnter", handleKeyPress, { ctrlKey: true });

  // Rest of your component code...
};

For more detailed examples and usage instructions, please check the documentation.

Contributions 🤝

Contributions to hookings are always welcome! If you have any ideas for new hooks or improvements to existing ones, feel free to open an issue or submit a pull request on GitHub.

License 📄

Hookings is open-source software licensed under the MIT License.

Conclusion 🎉

Thank you for using Hookings! We hope these custom hooks help improve your React development experience. If you encounter any issues or have any questions, don't hesitate to reach out on Github. Happy coding! 🚀

2.8.3

2 months ago

2.8.2

2 months ago

2.8.1

2 months ago

2.7.29

3 months ago

2.7.28

3 months ago

2.7.27

3 months ago

2.8.0

3 months ago

2.7.22

3 months ago

2.7.21

3 months ago

2.7.20

3 months ago

2.7.26

3 months ago

2.7.25

3 months ago

2.7.24

3 months ago

2.7.23

3 months ago

2.7.31

3 months ago

2.7.30

3 months ago

2.7.19

3 months ago

2.7.18

3 months ago

2.7.17

3 months ago

2.7.16

3 months ago

2.7.11

3 months ago

2.7.15

3 months ago

2.7.14

3 months ago

2.7.13

3 months ago

2.7.12

3 months ago

2.7.8

3 months ago

2.7.7

3 months ago

2.7.9

3 months ago

2.7.10

3 months ago

2.7.4

4 months ago

2.7.5

4 months ago

2.7.3

4 months ago

2.7.2

4 months ago

2.7.1

4 months ago

2.7.0

5 months ago

2.6.4

5 months ago

2.6.3

5 months ago

2.5.0

6 months ago

2.6.1

6 months ago

2.6.0

6 months ago

2.6.2

6 months ago

2.4.0

8 months ago

1.3.2

9 months ago

1.3.1

9 months ago

1.3.0

9 months ago

2.3.0

9 months ago

2.2.1

9 months ago

2.2.0

9 months ago

2.0.2

9 months ago

2.3.2

9 months ago

2.3.1

9 months ago

2.1.0

9 months ago

2.0.1

9 months ago

2.0.0

9 months ago

1.2.15

10 months ago

1.2.14

10 months ago

1.2.13

10 months ago

1.2.12

10 months ago

1.2.11

10 months ago

1.2.10

10 months ago

1.2.9

10 months ago

1.2.8

10 months ago

1.2.7

10 months ago

1.2.6

10 months ago

1.2.5

10 months ago

1.2.4

10 months ago

1.2.3

10 months ago

1.2.2

10 months ago

1.2.1

10 months ago

1.2.0

10 months ago

1.1.5

10 months ago

1.1.4

10 months ago

1.1.3

10 months ago

1.1.2

10 months ago

1.1.1

10 months ago

1.1.0

10 months ago

1.0.5

10 months ago

1.0.4

10 months ago

1.0.3

10 months ago

1.0.2

10 months ago

1.0.1

10 months ago