+55
| # use-shit | ||
|  | ||
|  | ||
| > The best use-hook ever made. | ||
| Use-shit is not just a tool. It is the best idea ever made | ||
| ## Installation: | ||
| ```bash | ||
| npm i use-shit | ||
| ``` | ||
| ## Usage | ||
| ```ts | ||
| import { useShit } from 'use-shit'; | ||
| const REAL_SHIT = [1, 2, 3, 4]; | ||
| const [shit] = useShit(REAL_SHIT); // shit === REAL_SHIT | ||
| ``` | ||
| ## Example | ||
| ```tsx | ||
| import React from 'react'; | ||
| import { useShit } from 'use-shit'; | ||
| const REAL_SHIT = [1, 2, 3, 4]; | ||
| export function App() { | ||
| const [shit] = useShit(REAL_SHIT); | ||
| return ( | ||
| <> | ||
| <p>Thanks god, My code is beautiful!</p> | ||
| <ul> | ||
| { shit.map((slice) => ( | ||
| <li key={slice}>{slice}</li> | ||
| )) } | ||
| </ul> | ||
| </> | ||
| ); | ||
| } | ||
| ``` | ||
| If you are thinking why not just use the `REAL_SHIT`, you are not a true hook based developer. Althorugh `REAL_SHIT` is equal to `shit`, but it's always nice to have some unnessesury `useShit` in body of components. | ||
| ## License | ||
| [MIT](./LICENSE) | ||
| --- | ||
|  |
+16
-0
| # Changelog | ||
| ## v0.0.2 | ||
| [compare changes](https://github.com/nainemom/use-shit/compare/v0.0.1...v0.0.2) | ||
| ### 🩹 Fixes | ||
| - Readme badges ([d612e22](https://github.com/nainemom/use-shit/commit/d612e22)) | ||
| ### 🏡 Chore | ||
| - Create readme ([0310e6f](https://github.com/nainemom/use-shit/commit/0310e6f)) | ||
| ### ❤️ Contributors | ||
| - Amir Momenian <nainemom@gmail.com> | ||
| ## v0.0.1 | ||
@@ -5,0 +21,0 @@ |
+1
-1
| { | ||
| "name": "use-shit", | ||
| "version": "0.0.1", | ||
| "version": "0.0.2", | ||
| "description": "The best use-hook ever made.", | ||
@@ -5,0 +5,0 @@ "type": "module", |
No README
QualityPackage does not have a README. This may indicate a failed publish or a low quality package.
Found 1 instance in 1 package
4635
46.08%11
10%1
-50%56
Infinity%