@usefy/usefy 0.0.2

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -0,0 +1,8 @@
1
+ export { useCounter } from '@usefy/use-counter';
2
+ export { UseToggleReturn, useToggle } from '@usefy/use-toggle';
3
+ export { UseDebounceOptions, useDebounce } from '@usefy/use-debounce';
4
+ export { DebouncedFunction, UseDebounceCallbackOptions, useDebounceCallback } from '@usefy/use-debounce-callback';
5
+ export { UseThrottleOptions, useThrottle } from '@usefy/use-throttle';
6
+ export { ThrottledFunction, UseThrottleCallbackOptions, useThrottleCallback } from '@usefy/use-throttle-callback';
7
+ export { InitialValue, UseLocalStorageOptions, UseLocalStorageReturn, useLocalStorage } from '@usefy/use-local-storage';
8
+ export { InitialValue as SessionStorageInitialValue, UseSessionStorageOptions, UseSessionStorageReturn, useSessionStorage } from '@usefy/use-session-storage';
@@ -0,0 +1,8 @@
1
+ export { useCounter } from '@usefy/use-counter';
2
+ export { UseToggleReturn, useToggle } from '@usefy/use-toggle';
3
+ export { UseDebounceOptions, useDebounce } from '@usefy/use-debounce';
4
+ export { DebouncedFunction, UseDebounceCallbackOptions, useDebounceCallback } from '@usefy/use-debounce-callback';
5
+ export { UseThrottleOptions, useThrottle } from '@usefy/use-throttle';
6
+ export { ThrottledFunction, UseThrottleCallbackOptions, useThrottleCallback } from '@usefy/use-throttle-callback';
7
+ export { InitialValue, UseLocalStorageOptions, UseLocalStorageReturn, useLocalStorage } from '@usefy/use-local-storage';
8
+ export { InitialValue as SessionStorageInitialValue, UseSessionStorageOptions, UseSessionStorageReturn, useSessionStorage } from '@usefy/use-session-storage';
package/dist/index.js ADDED
@@ -0,0 +1,52 @@
1
+ "use strict";
2
+ var __defProp = Object.defineProperty;
3
+ var __getOwnPropDesc = Object.getOwnPropertyDescriptor;
4
+ var __getOwnPropNames = Object.getOwnPropertyNames;
5
+ var __hasOwnProp = Object.prototype.hasOwnProperty;
6
+ var __export = (target, all) => {
7
+ for (var name in all)
8
+ __defProp(target, name, { get: all[name], enumerable: true });
9
+ };
10
+ var __copyProps = (to, from, except, desc) => {
11
+ if (from && typeof from === "object" || typeof from === "function") {
12
+ for (let key of __getOwnPropNames(from))
13
+ if (!__hasOwnProp.call(to, key) && key !== except)
14
+ __defProp(to, key, { get: () => from[key], enumerable: !(desc = __getOwnPropDesc(from, key)) || desc.enumerable });
15
+ }
16
+ return to;
17
+ };
18
+ var __toCommonJS = (mod) => __copyProps(__defProp({}, "__esModule", { value: true }), mod);
19
+
20
+ // src/index.ts
21
+ var index_exports = {};
22
+ __export(index_exports, {
23
+ useCounter: () => import_use_counter.useCounter,
24
+ useDebounce: () => import_use_debounce.useDebounce,
25
+ useDebounceCallback: () => import_use_debounce_callback.useDebounceCallback,
26
+ useLocalStorage: () => import_use_local_storage.useLocalStorage,
27
+ useSessionStorage: () => import_use_session_storage.useSessionStorage,
28
+ useThrottle: () => import_use_throttle.useThrottle,
29
+ useThrottleCallback: () => import_use_throttle_callback.useThrottleCallback,
30
+ useToggle: () => import_use_toggle.useToggle
31
+ });
32
+ module.exports = __toCommonJS(index_exports);
33
+ var import_use_counter = require("@usefy/use-counter");
34
+ var import_use_toggle = require("@usefy/use-toggle");
35
+ var import_use_debounce = require("@usefy/use-debounce");
36
+ var import_use_debounce_callback = require("@usefy/use-debounce-callback");
37
+ var import_use_throttle = require("@usefy/use-throttle");
38
+ var import_use_throttle_callback = require("@usefy/use-throttle-callback");
39
+ var import_use_local_storage = require("@usefy/use-local-storage");
40
+ var import_use_session_storage = require("@usefy/use-session-storage");
41
+ // Annotate the CommonJS export names for ESM import in node:
42
+ 0 && (module.exports = {
43
+ useCounter,
44
+ useDebounce,
45
+ useDebounceCallback,
46
+ useLocalStorage,
47
+ useSessionStorage,
48
+ useThrottle,
49
+ useThrottleCallback,
50
+ useToggle
51
+ });
52
+ //# sourceMappingURL=index.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"sources":["../src/index.ts"],"sourcesContent":["// Re-export all hooks from individual packages\r\n\r\n// useCounter\r\nexport { useCounter } from \"@usefy/use-counter\";\r\n\r\n// useToggle\r\nexport { useToggle, type UseToggleReturn } from \"@usefy/use-toggle\";\r\n\r\n// useDebounce\r\nexport { useDebounce, type UseDebounceOptions } from \"@usefy/use-debounce\";\r\n\r\n// useDebounceCallback\r\nexport {\r\n useDebounceCallback,\r\n type UseDebounceCallbackOptions,\r\n type DebouncedFunction,\r\n} from \"@usefy/use-debounce-callback\";\r\n\r\n// useThrottle\r\nexport { useThrottle, type UseThrottleOptions } from \"@usefy/use-throttle\";\r\n\r\n// useThrottleCallback\r\nexport {\r\n useThrottleCallback,\r\n type UseThrottleCallbackOptions,\r\n type ThrottledFunction,\r\n} from \"@usefy/use-throttle-callback\";\r\n\r\n// useLocalStorage\r\nexport {\r\n useLocalStorage,\r\n type UseLocalStorageOptions,\r\n type UseLocalStorageReturn,\r\n type InitialValue,\r\n} from \"@usefy/use-local-storage\";\r\n\r\n// useSessionStorage\r\nexport {\r\n useSessionStorage,\r\n type UseSessionStorageOptions,\r\n type UseSessionStorageReturn,\r\n type InitialValue as SessionStorageInitialValue,\r\n} from \"@usefy/use-session-storage\";\r\n"],"mappings":";;;;;;;;;;;;;;;;;;;;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAGA,yBAA2B;AAG3B,wBAAgD;AAGhD,0BAAqD;AAGrD,mCAIO;AAGP,0BAAqD;AAGrD,mCAIO;AAGP,+BAKO;AAGP,iCAKO;","names":[]}
package/dist/index.mjs ADDED
@@ -0,0 +1,28 @@
1
+ // src/index.ts
2
+ import { useCounter } from "@usefy/use-counter";
3
+ import { useToggle } from "@usefy/use-toggle";
4
+ import { useDebounce } from "@usefy/use-debounce";
5
+ import {
6
+ useDebounceCallback
7
+ } from "@usefy/use-debounce-callback";
8
+ import { useThrottle } from "@usefy/use-throttle";
9
+ import {
10
+ useThrottleCallback
11
+ } from "@usefy/use-throttle-callback";
12
+ import {
13
+ useLocalStorage
14
+ } from "@usefy/use-local-storage";
15
+ import {
16
+ useSessionStorage
17
+ } from "@usefy/use-session-storage";
18
+ export {
19
+ useCounter,
20
+ useDebounce,
21
+ useDebounceCallback,
22
+ useLocalStorage,
23
+ useSessionStorage,
24
+ useThrottle,
25
+ useThrottleCallback,
26
+ useToggle
27
+ };
28
+ //# sourceMappingURL=index.mjs.map
@@ -0,0 +1 @@
1
+ {"version":3,"sources":["../src/index.ts"],"sourcesContent":["// Re-export all hooks from individual packages\r\n\r\n// useCounter\r\nexport { useCounter } from \"@usefy/use-counter\";\r\n\r\n// useToggle\r\nexport { useToggle, type UseToggleReturn } from \"@usefy/use-toggle\";\r\n\r\n// useDebounce\r\nexport { useDebounce, type UseDebounceOptions } from \"@usefy/use-debounce\";\r\n\r\n// useDebounceCallback\r\nexport {\r\n useDebounceCallback,\r\n type UseDebounceCallbackOptions,\r\n type DebouncedFunction,\r\n} from \"@usefy/use-debounce-callback\";\r\n\r\n// useThrottle\r\nexport { useThrottle, type UseThrottleOptions } from \"@usefy/use-throttle\";\r\n\r\n// useThrottleCallback\r\nexport {\r\n useThrottleCallback,\r\n type UseThrottleCallbackOptions,\r\n type ThrottledFunction,\r\n} from \"@usefy/use-throttle-callback\";\r\n\r\n// useLocalStorage\r\nexport {\r\n useLocalStorage,\r\n type UseLocalStorageOptions,\r\n type UseLocalStorageReturn,\r\n type InitialValue,\r\n} from \"@usefy/use-local-storage\";\r\n\r\n// useSessionStorage\r\nexport {\r\n useSessionStorage,\r\n type UseSessionStorageOptions,\r\n type UseSessionStorageReturn,\r\n type InitialValue as SessionStorageInitialValue,\r\n} from \"@usefy/use-session-storage\";\r\n"],"mappings":";AAGA,SAAS,kBAAkB;AAG3B,SAAS,iBAAuC;AAGhD,SAAS,mBAA4C;AAGrD;AAAA,EACE;AAAA,OAGK;AAGP,SAAS,mBAA4C;AAGrD;AAAA,EACE;AAAA,OAGK;AAGP;AAAA,EACE;AAAA,OAIK;AAGP;AAAA,EACE;AAAA,OAIK;","names":[]}
package/package.json ADDED
@@ -0,0 +1,59 @@
1
+ {
2
+ "name": "@usefy/usefy",
3
+ "version": "0.0.2",
4
+ "description": "A collection of useful React hooks",
5
+ "main": "./dist/index.js",
6
+ "module": "./dist/index.mjs",
7
+ "types": "./dist/index.d.ts",
8
+ "exports": {
9
+ ".": {
10
+ "types": "./dist/index.d.ts",
11
+ "import": "./dist/index.mjs",
12
+ "require": "./dist/index.js"
13
+ }
14
+ },
15
+ "files": [
16
+ "dist"
17
+ ],
18
+ "sideEffects": false,
19
+ "dependencies": {
20
+ "@usefy/use-debounce-callback": "0.0.2",
21
+ "@usefy/use-counter": "0.0.2",
22
+ "@usefy/use-throttle-callback": "0.0.2",
23
+ "@usefy/use-toggle": "0.0.2",
24
+ "@usefy/use-debounce": "0.0.2",
25
+ "@usefy/use-local-storage": "0.0.2",
26
+ "@usefy/use-throttle": "0.0.2",
27
+ "@usefy/use-session-storage": "0.0.2"
28
+ },
29
+ "peerDependencies": {
30
+ "react": "^18.0.0 || ^19.0.0"
31
+ },
32
+ "devDependencies": {
33
+ "@types/react": "^19.0.0",
34
+ "rimraf": "^6.0.1",
35
+ "tsup": "^8.0.0",
36
+ "typescript": "^5.0.0"
37
+ },
38
+ "publishConfig": {
39
+ "access": "public"
40
+ },
41
+ "repository": {
42
+ "type": "git",
43
+ "url": "https://github.com/geon0529/usefy.git",
44
+ "directory": "packages/usefy"
45
+ },
46
+ "license": "MIT",
47
+ "keywords": [
48
+ "react",
49
+ "hooks",
50
+ "custom-hooks",
51
+ "usefy"
52
+ ],
53
+ "scripts": {
54
+ "build": "tsup",
55
+ "dev": "tsup --watch",
56
+ "typecheck": "tsc --noEmit",
57
+ "clean": "rimraf dist"
58
+ }
59
+ }