Skip to content

Commit aac85c7

Browse files
committed
useFloatToolkit hook / ReactFT
1 parent 731ab9e commit aac85c7

File tree

4 files changed

+297
-189
lines changed

4 files changed

+297
-189
lines changed

README.md

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -25,7 +25,7 @@ npm install @float-toolkit/react
2525

2626
### Usage
2727

28-
The package export is a **React hook** called `useFloatToolkit`. It can be called from within a Function Component to create an outlet (reactive output).
28+
The package export is a **React hook** called `useFloatToolkit`. It returns an object with an `output` state, as well as math functions that also serve as setters for the output.
2929

3030
```js
3131
import React, { useEffect } from "react";
@@ -58,7 +58,7 @@ import useFloatToolkit, { ReactFT } from "@float-toolkit/react";
5858

5959
interface Props {
6060
numbers: number[];
61-
precision: ReactFT.Precision;
61+
precision?: ReactFT.Precision;
6262
}
6363

6464
const Sum: FC = (props) => {

package-lock.json

Lines changed: 186 additions & 186 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

package.json

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -42,4 +42,3 @@
4242
"typescript": "^4.7.2"
4343
}
4444
}
45-

0 commit comments

Comments
 (0)