1.0.0-alpha.13 • Published 11 days ago

@ridgehkr/useful v1.0.0-alpha.13

Weekly downloads
-
License
MIT
Repository
github
Last release
11 days ago

useFul: a React Hooks Library

Welcome to useFul! This library provides a collection of efficient and modern React hooks to enhance your application development experience. These hooks are designed to simplify common tasks, improve code reusability, and promote best practices in your React projects. useFul is written in TypeScript, uses Vite for its development environment, and Vitest for unit testing.

useFul officially supports React v18.0 and newer.

Documentation

Read the full documentation at https://docs.usefulhooks.com.

Installation

npm install @ridgehkr/useful

Or, with Yarn:

yarn add @ridgehkr/useful

Development

This project uses Yarn as its package manager. To get started, first install all project dependencies:

yarn

Spin up the development server:

npm run dev

Or, with Yarn:

yarn dev

All hooks live in /src/hooks/, and their associated unit tests are in /src/tests/. Every hook follows the standard hook naming convention of "usehook capability", e.g. useFetch or useLocalStorage.

Unit test files use the name format of [hook name].test.tsx, e.g. useFetch.test.tsx or useLocalStorage.test.tsx. All unit tests for a hook should exist in their associated test file and nowhere else.

Unit tests

useFul relies on Vitest for its unit testing framework. The test results can be seen either in the console (test task) or in a browser (test:ui). The scripts, when running, will watch your test files and automatically run again when any changes are made.

Note that most hooks don't have unit tests yet. If you'd like to contribute to this effort, please submit a pull request!

Test Scripts

Run all tests in the console:

npm run test

Or, with Yarn:

yarn test

Run all unit tests as well as Vitest's live test status UI:

npm run test:ui

Or, with Yarn:

yarn test:ui

Contributing

useFul thrives on contributions from developers like you! If you encounter issues or have any suggestions for improvements, please feel free to contribute by opening an issue or submitting a pull request in the GitHub repository.

License

This project is licensed under the MIT License.

Written by Caleb Pierce.

1.0.0-alpha.13

11 days ago

1.0.0-alpha.12c

1 month ago

1.0.0-alpha.12b

1 month ago

1.0.0-alpha.12a

1 month ago

1.0.0-alpha.12

1 month ago

1.0.0-alpha.11

1 month ago

1.0.0-alpha.10b

2 months ago

1.0.0-alpha.10a

2 months ago

1.0.0-alpha.9b

2 months ago

1.0.0-alpha.9a

2 months ago

1.0.0-alpha.9

2 months ago

1.0.0-alpha.7

4 months ago

1.0.0-alpha.6

4 months ago

1.0.0-alpha.8

4 months ago

1.0.0-alpha.1

8 months ago