@rbxts/pretty-roact-hooks
TypeScript icon, indicating that this package has built-in type declarations

3.2.1 • Public • Published

🌺 pretty-roact-hooks

GitHub Workflow Status npm version npm downloads GitHub license

An opinionated collection of useful hooks and utilites for Roblox-TS and Roact Hooked.

Every hook has documentation and tests. If you find a bug or have a feature request, please open an issue.

 

Check out some featured hooks:

  • 🦾 useMotor - Creates a motor and returns a binding, a function to set the goal, and a motor API
  • ⏱️ useAsync - A hook that runs an async function and returns the result and status
  • ⚙️ useProperty - Tracks the state of one or more instance properties without refs

This package also exports some useful utilities:

Or, see the full list of hooks.

 

📦 Installation

This package is available for Roblox TypeScript projects on NPM.

npm install @rbxts/pretty-roact-hooks @rbxts/flipper @rbxts/roact-hooked

or

pnpm add @rbxts/pretty-roact-hooks @rbxts/flipper @rbxts/roact-hooked

 

🌻 Contributing

Contributions are welcome! Note that if you make a change to a hook, you should also check the tests and documentation.

To get started, clone the repository and run npm install or pnpm install. Then, you can run the following commands:

  • pnpm dev - Enable watch mode with the game project type
  • pnpm build - Build the package

You will likely need the following extensions:

 

📝 License

pretty-roact-hooks is licensed under the MIT License.

Package Sidebar

Install

npm i @rbxts/pretty-roact-hooks

Weekly Downloads

17

Version

3.2.1

License

MIT

Unpacked Size

222 kB

Total Files

257

Last publish

Collaborators

  • littensy