@dxtmisha/functional-basic 1.8.4 → 1.8.5

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.
package/CHANGELOG.md CHANGED
@@ -2,6 +2,11 @@
2
2
 
3
3
  All notable changes to this project will be documented in this file.
4
4
 
5
+ ## [1.8.5] - 2026-08-05
6
+
7
+ ### Changed
8
+ - **AI Documentation**: Updated JSDoc prompt rules, added MCP resource definitions (`ai-mcp.json`), removed redundant prompt files, and updated package metadata (`ai-description.md`, `ai-types.md`).
9
+
5
10
  ## [1.8.4] - 2026-08-05
6
11
 
7
12
  ### Changed
package/ai-description.md CHANGED
@@ -1,11 +1,4 @@
1
- This library serves as a comprehensive isomorphic runtime toolkit providing core utility primitives for HTTP networking, state persistence, internationalization, metadata management, DOM manipulation, and data transformation across browser and server-side rendering environments.
2
-
3
- Its main capabilities are organized into high-level functional groupings: API and network utilities handle HTTP request orchestration, response caching, structured error normalization, retry strategies, and SSR hydration script generation; storage utilities manage cookies, local and session storage, request-isolated server storage, and inter-tab broadcast messaging; internationalization and localization modules process geographic standards, timezone conversions, localized number/date/unit formatting, phone masking, and pluralization rules; DOM and event helpers provide lifecycle-managed event listeners, smooth scrolling, visibility checks, element creation, and global loading indicators; metadata modules provide a unified interface to generate and manage HTML, Open Graph, and Twitter Card tags; and data processing functions handle string transformations, deep copying, template replacement, fuzzy searching with query highlighting, and list sorting.
4
-
5
- It is mandatory to study "ai-types.md" when configuring typed API request payloads and hooks, defining custom error center callbacks, constructing complex localized formatter options, implementing schema-driven search or sorting parameters, or working with environment-specific storage contracts.
6
-
7
- The library integrates into modern web application stacks by offering framework-agnostic utilities that safely detect browser versus SSR runtimes while supporting seamless client hydration workflows.
1
+ The library provides an isomorphic suite of client- and server-side utilities designed for web application infrastructure, state management, internationalization, and network communication, serving as a unified foundation for API lifecycle management, SSR hydration, browser storage, and data transformation across JavaScript runtimes. API and network utilities streamline HTTP fetch requests with configurable defaults, automatic retries with jitter, response caching, error classification, and SSR client hydration script generation. Storage and state management modules supply request-isolated SSR storage contexts, type-safe cookie management, synchronized URL query and hash state, local and session storage with age-based expiration, and cross-tab broadcast messaging. Localization and geographic tools provide automated country and language detection, phone number mask matching, metric-to-imperial unit conversion, pluralization, currency formatting, and asynchronous multi-language translation resolution. Search and data handling capabilities enable multi-column list searching, search match highlighting, fuzzy and exact regular expression matching, multi-field array sorting, and recursive object template replacement. UI, DOM, and event helpers deliver DOM element manipulation, ResizeObserver and scroll-sync event listeners, global loading indicators, icon registration, resumable timers, and isomorphic HTML meta tag management for standard SEO, Open Graph, and Twitter Cards. Studying type definitions in ai-types.md is mandatory when typing complex API request or response structures, configuring custom request wrappers, defining criteria for error storage items, specifying search column paths, setting up custom translation dictionaries, or implementing isolated server storage contexts during SSR. This package connects with modern web frameworks and SSR environments by wrapping standard Web APIs, fetch interfaces, and DOM listeners with environment-agnostic abstractions and automated client-side hydration hooks.
8
2
  ## Mandatory Rules
9
- Read the corresponding file if your task relates to:
10
- - 'node_modules/@dxtmisha/functional-basic/ai-prompts/api-reference.md': HTTP client, caching, storage, geolocation, localization, formatting, DOM events, and utility helpers
11
- - 'node_modules/@dxtmisha/functional-basic/ai-prompts/coding-standards.md': Class structure, typing standards, SSR safety, and primitive helper functions
3
+ Read the corresponding file ONLY when working on a task related to (even if not working directly with this package):
4
+ - 'node_modules/@dxtmisha/functional-basic/ai-prompts/api-reference.md': HTTP client caching, storage management, geolocation localization, and DOM utility helpers
package/ai-doc.md CHANGED
@@ -1 +1,8 @@
1
- Framework-agnostic utility library. **Vue developers MUST search `@dxtmisha/functional` first**; use this ONLY if no reactive/Vue-specific analog exists.
1
+ Framework-agnostic utility library. **Vue developers MUST search `@dxtmisha/functional` first**; use this ONLY if no reactive/Vue-specific analog exists.
2
+
3
+ ## Coding Standards & Conventions
4
+
5
+ - **Class Structure**: Properties/Variables (`public`->`protected`->`private`) -> Constructor -> Public Methods -> Protected Methods -> Private Methods. Within each method group, follow order: 1) `get` / `set` (getters/setters), 2) `is...` / `has...`, 3) `get...` / `set...`, 4) `add...` / `remove...`, 5) `update...` / `reset...`, 6) remaining methods. Within each subgroup, methods are grouped semantically by logical pairs and rules (e.g., `min` / `max`, `width` / `height`, `x` / `y` / `z`), and remaining methods are sorted alphabetically.
6
+ - **Style/Types**: `PascalCase` classes, `camelCase` methods/props, `UPPER_SNAKE_CASE` constants. No `any` (use `unknown`/generics). Explicit return types for ALL methods. Export all interfaces. Type files: `*Types.ts`. Use `@effect/schema` for schemas.
7
+ - **SSR Safety**: Isomorphic code. Do NOT store request state in globals. Use `isDomRuntime()` before `window`/`document`. Use `ServerStorage.get('key', () => new Class())` for request-isolated singletons.
8
+ - **Utility & Primitive Functions**: ALWAYS use primitive helper functions from this package (e.g. `isFunction`, `executeFunction`, `isFilled`, `isObject`, `isString`, `isArray`, etc.) instead of writing custom inline checks or conditions.
package/ai-mcp.json CHANGED
@@ -1,26 +1,20 @@
1
1
  [
2
2
  {
3
3
  "uri": "@dxtmisha/functional-basic/ai-types.md",
4
- "name": "TypeScript Type Definitions",
4
+ "name": "TypeScript Types Reference (@dxtmisha/functional-basic)",
5
5
  "mimeType": "text/markdown",
6
- "description": "Comprehensive TypeScript type definitions, enums, class interfaces, and utility function signatures for API request handling, internationalization, and client-side data management."
6
+ "description": "Comprehensive TypeScript type definitions, enums, classes, and utility function declarations covering API client interfaces, metadata management, internationalization, and DOM utilities."
7
7
  },
8
8
  {
9
9
  "uri": "@dxtmisha/functional-basic/ai-description.md",
10
- "name": "Isomorphic Utility Toolkit",
10
+ "name": "Utility Library Overview (@dxtmisha/functional-basic)",
11
11
  "mimeType": "text/markdown",
12
- "description": "Provides an architectural overview of the isomorphic runtime toolkit covering HTTP networking, state persistence, i18n, DOM helpers, and metadata management across browser and SSR environments. Details core utility capabilities and outlines mandatory cross-referencing rules for API references, types, and coding standards."
12
+ "description": "Provides an overview of isomorphic client and server utilities for HTTP networking, state management, localization, data search, DOM handling, and SSR hydration. Outlines architectural conventions and package capabilities across browser and server runtimes."
13
13
  },
14
14
  {
15
15
  "uri": "@dxtmisha/functional-basic/ai-prompts/api-reference.md",
16
- "name": "API Reference Guide",
16
+ "name": "API Reference Guide (@dxtmisha/functional-basic)",
17
17
  "mimeType": "text/markdown",
18
- "description": "API reference and code usage examples for @dxtmisha/functional-basic, detailing HTTP clients, caching, storage, geolocation, DOM events, and general utilities."
19
- },
20
- {
21
- "uri": "@dxtmisha/functional-basic/ai-prompts/coding-standards.md",
22
- "name": "Coding Standards",
23
- "mimeType": "text/markdown",
24
- "description": "Architectural conventions, class structure rules, SSR safety guidelines, and TypeScript typing standards for code implementation."
18
+ "description": "Comprehensive API reference and usage examples for the `@dxtmisha/functional-basic` package. Covers HTTP client configurations, caching, state storage, localization, DOM events, and core utility functions."
25
19
  }
26
20
  ]
package/ai-types.md CHANGED
@@ -535,7 +535,6 @@ export type TranslateDataFileItem = () => Promise<TranslateDataFileList>;
535
535
  export type TranslateDataFile = Record<string, TranslateDataFileItem>;
536
536
  export declare const TRANSLATE_GLOBAL_PREFIX = "global";
537
537
  export declare const TRANSLATE_TIME_OUT = 160;
538
- export declare const errorCauseList: ErrorCenterCauseList;
539
538
  export declare class Api {
540
539
  static isLocalhost(): boolean;
541
540
  static getItem(): ApiInstance;
@@ -690,34 +689,20 @@ export declare class BroadcastMessage<Message = any> {
690
689
  setCallbackError(callbackError: (event: MessageEvent<Message>) => void): this;
691
690
  destroy(): this;
692
691
  }
693
- /** @deprecated This class is obsolete and should not be used */
694
692
  export declare class Cache {
695
693
  get<T>(name: string, callback: () => T, comparison?: any[]): T;
696
694
  getAsync<T>(name: string, callback: () => T, comparison?: any[]): Promise<T>;
697
695
  }
698
- /** @deprecated This class is obsolete and should not be used */
699
696
  export declare class CacheItem<T> {
700
697
  constructor(callback: () => T);
701
698
  getCache(comparison: any[]): T;
702
699
  getCacheOld(): T | undefined;
703
700
  getCacheAsync(comparison: any[]): Promise<T>;
704
701
  }
705
- /** @deprecated This class is obsolete and should not be used */
706
702
  export declare class CacheStatic {
707
703
  static get<T>(name: string, callback: () => T, comparison?: any[]): T;
708
704
  static getAsync<T>(name: string, callback: () => T, comparison?: any[]): Promise<T>;
709
705
  }
710
- export type CookieSameSite = 'strict' | 'lax';
711
- export type CookieOptions = {
712
- age?: number;
713
- sameSite?: CookieSameSite;
714
- path?: string;
715
- domain?: string;
716
- secure?: boolean;
717
- httpOnly?: boolean;
718
- partitioned?: boolean;
719
- arguments?: string[] | Record<string, string | number | boolean>;
720
- };
721
706
  export declare class Cookie<T> {
722
707
  static getInstance<T>(name: string): Cookie<T>;
723
708
  constructor(name: string);
@@ -734,6 +719,17 @@ export declare class CookieBlockInstance {
734
719
  get(): boolean;
735
720
  set(value: boolean): void;
736
721
  }
722
+ export type CookieSameSite = 'strict' | 'lax';
723
+ export type CookieOptions = {
724
+ age?: number;
725
+ sameSite?: CookieSameSite;
726
+ path?: string;
727
+ domain?: string;
728
+ secure?: boolean;
729
+ httpOnly?: boolean;
730
+ partitioned?: boolean;
731
+ arguments?: string[] | Record<string, string | number | boolean>;
732
+ };
737
733
  export declare class CookieStorage {
738
734
  static init(getListener?: (key: string) => any | undefined, getListenerRaw?: () => string, setListener?: (key: string, value: any, cookie: string, options?: CookieOptions) => void): void;
739
735
  static reset(): void;
@@ -751,9 +747,12 @@ export declare class DataStorage<T> {
751
747
  update(): this;
752
748
  }
753
749
  /**
750
+ * A class for working with dates and localized date-time operations.
751
+ *
754
752
  * @remarks
755
- * Creating a `Datetime` instance without a specific date (using current time)
756
- * in SSR may lead to hydration mismatches.
753
+ * Creating a `Datetime` instance without a specific date (using the current time)
754
+ * for rendering in SSR may lead to hydration mismatches because the time or time zone
755
+ * on the server may differ from the time on the client.
757
756
  */
758
757
  export declare class Datetime {
759
758
  constructor(date?: NumberOrStringOrDate, type?: GeoDate, code?: string);
@@ -862,6 +861,25 @@ export declare class ErrorCenterInstance {
862
861
  setIsConsole(isConsole: ErrorCenterHandlerIsConsole): this;
863
862
  on(cause: ErrorCenterCauseItem): this;
864
863
  }
864
+ /**
865
+ * Advanced wrapper for managing event listeners on DOM elements or the `window` object.
866
+ *
867
+ * ### Key Features:
868
+ * - Lifecycle Control: Easily `start`, `stop`, `toggle`, or `reset` event listeners.
869
+ * - DOM Safety: Automatically halts the event if the target element is removed from the DOM.
870
+ * - Specialized Optimizations:
871
+ * - `resize`: Uses `ResizeObserver` for any HTML element (not limited to `window`).
872
+ * - `scroll-sync`: High-performance scroll tracking using `requestAnimationFrame`.
873
+ * - Dynamic Configuration: Chained setters for target element, event type, listener, and options.
874
+ * - Custom Event Dispatching: Built-in support for triggering events with custom data via `dispatch`.
875
+ * - Strict Typing: Generic support for elements, event objects, and custom detail data.
876
+ *
877
+ * @example
878
+ * ```typescript
879
+ * const clickEvent = new EventItem('.btn', 'click', (e) => console.log('Clicked!'));
880
+ * clickEvent.start();
881
+ * ```
882
+ */
865
883
  export declare class EventItem<E extends ElementOrWindow, O extends Event, D extends Record<string, any> = Record<string, any>> {
866
884
  constructor(elementSelector?: ElementOrString<E>, type?: string | string[], listener?: EventListenerDetail<O, D> | undefined, options?: EventOptions, detail?: D | undefined);
867
885
  isActive(): boolean;
@@ -1025,7 +1043,8 @@ export declare class Hash {
1025
1043
  static removeWatch<T>(name: string, callback: (value: T) => void): void;
1026
1044
  static reload(): void;
1027
1045
  }
1028
- export declare class HashInstance extends UrlInstanceAbstract {}
1046
+ export declare class HashInstance extends UrlInstanceAbstract {
1047
+ }
1029
1048
  export type IconsItem = string | Promise<string | any> | (() => Promise<string | any>);
1030
1049
  export type IconsConfig = {
1031
1050
  url?: string;
@@ -1176,7 +1195,8 @@ export declare class Query {
1176
1195
  static removeWatch<T>(name: string, callback: (value: T) => void): void;
1177
1196
  static reload(): void;
1178
1197
  }
1179
- export declare class QueryInstance extends UrlInstanceAbstract {}
1198
+ export declare class QueryInstance extends UrlInstanceAbstract {
1199
+ }
1180
1200
  export declare class ResumableTimer {
1181
1201
  constructor(callback: FunctionVoid, delay?: number, blockStart?: boolean);
1182
1202
  resume(): this;
@@ -1252,7 +1272,7 @@ export declare class ServerStorage {
1252
1272
  static reset(): void;
1253
1273
  static has(key: string): boolean;
1254
1274
  static get<T = any>(key: string, defaultValue?: () => T, hydration?: boolean): T;
1255
- static set<T = any>(key: string, value: () => T, hydration?: boolean, storageList?: ServerStorageList): T;
1275
+ static set<T = any>(key: string, value: () => T, hydration?: boolean, storageList?: Record<string, any>): T;
1256
1276
  static setErrorStatus(hide: boolean): void;
1257
1277
  static remove(key: string): void;
1258
1278
  static toString(): string;
@@ -1341,15 +1361,19 @@ export declare class UrlItem {
1341
1361
  }
1342
1362
  export declare function addTagHighlightMatch(value: string, search?: string | RegExp, className?: string, shouldEscape?: boolean): string;
1343
1363
  export declare function anyToString<V>(value: V, isArrayString?: boolean, trim?: boolean): string;
1344
- export declare function applyTemplate(text: string, replacement?: Record<string, string | number | boolean> | string[]): string;
1364
+ export declare const applyTemplate: (text: string, replacement?: Record<string, string | number | boolean> | string[]) => string;
1345
1365
  export declare function arrFill<T>(value: T, count: number): T[];
1346
1366
  export declare function blobToBase64(blob: Blob, clean?: boolean): Promise<string | undefined>;
1347
1367
  export declare function capitalize(value: string, isLocale?: boolean): string;
1348
1368
  export declare function copyObject<T>(value: T): T;
1349
1369
  export declare function copyObjectLite<T, R = T>(value: T, source?: any): R;
1350
1370
  /**
1371
+ * Creates an HTML element with the specified tag name and options.
1372
+ *
1351
1373
  * @remarks
1352
- * Always returns `undefined` when running on server.
1374
+ * When running on the server, the function always returns `undefined`.
1375
+ * If you use it within a component's rendering logic, it may lead to hydration mismatches.
1376
+ * It is recommended to call this function only inside lifecycle hooks that run exclusively on the client (e.g., `onMounted` in Vue or `useEffect` in React).
1353
1377
  */
1354
1378
  export declare function createElement<T extends HTMLElement>(parentElement?: HTMLElement, tagName?: string, options?: Partial<T> | Record<keyof T, T[keyof T]> | ((element: T) => void), referenceElement?: HTMLElement): T | undefined;
1355
1379
  export declare function domContentLoaded<T = void>(callback: () => T | Promise<T>): Promise<T>;
@@ -1369,23 +1393,33 @@ export declare function getAttributes<E extends ElementOrWindow>(element?: Eleme
1369
1393
  export declare function getClipboardData(event?: ClipboardEvent): Promise<string>;
1370
1394
  export declare function getColumn<T, K extends keyof T>(array: ObjectOrArray<T>, column: K): (T[K] | undefined)[];
1371
1395
  /**
1396
+ * Returns the current date in the specified format.
1397
+ *
1372
1398
  * @remarks
1373
- * Using in SSR may cause hydration mismatches.
1399
+ * Using this function for rendering in SSR may lead to hydration mismatches
1400
+ * because the time or time zone on the server may differ from the time on the client.
1401
+ * It is recommended to use this function inside client-side hooks only (e.g., `onMounted` in Vue or `useEffect` in React).
1374
1402
  */
1375
1403
  export declare function getCurrentDate(format?: GeoDate): string;
1376
1404
  /**
1405
+ * Returns the current time in milliseconds.
1406
+ *
1377
1407
  * @remarks
1378
- * Using in SSR will cause hydration mismatches.
1408
+ * Using this function for rendering in SSR will almost certainly lead to hydration mismatches
1409
+ * because the timestamp on the server will differ from the timestamp on the client.
1379
1410
  */
1380
1411
  export declare function getCurrentTime(): number;
1381
1412
  export declare function getElement<E extends ElementOrWindow, R extends Exclude<E, Window>>(element?: ElementOrString<E>): R | undefined;
1382
1413
  export declare function getElementId<E extends ElementOrWindow>(element?: ElementOrString<E>, selector?: string): string;
1383
1414
  /**
1384
- * @warning Initialization mandatory for correct SSR functioning.
1415
+ * Initializes getElementId with a context provider.
1416
+ *
1417
+ * @warning
1418
+ * Mandatory for correct SSR behavior on both server and client.
1419
+ *
1385
1420
  * @example
1386
1421
  * ```typescript
1387
1422
  * import { useId } from 'vue'
1388
- * import { initGetElementId } from '@dxtmisha/functional-basic'
1389
1423
  * initGetElementId(() => useId())
1390
1424
  * ```
1391
1425
  */
@@ -1456,7 +1490,7 @@ export declare function removeCommonPrefix(mainStr: string, prefix: string): str
1456
1490
  export declare const replaceComponentName: (text: string | undefined, name: string, componentName: string) => string | undefined;
1457
1491
  export declare function replaceRecursive<I>(array: ObjectItem<I>, replacement?: ObjectOrArray<I>, isMerge?: boolean): ObjectItem<I>;
1458
1492
  export declare function replaceTemplate(value: string, replaces: Record<string, string | FunctionReturn<string>>): string;
1459
- export type ResizeImageByMaxType = 'auto' | 'width' | 'height';
1493
+ type ResizeImageByMaxType = 'auto' | 'width' | 'height';
1460
1494
  export declare function resizeImageByMax(image: HTMLImageElement | string, maxSize: number, type?: ResizeImageByMaxType, typeData?: string): string | undefined;
1461
1495
  export declare function secondToTime(second: number | string | undefined, hasHour?: boolean): string;
1462
1496
  export declare function setElementItem<E extends ElementOrWindow, K extends keyof E, V extends E[K] = E[K]>(element: ElementOrString<E>, index: K, value: V | Record<string, V>): E | undefined;
@@ -1476,6 +1510,14 @@ export declare function toCamelCase(value: string): string;
1476
1510
  export declare function toCamelCaseFirst(value: string): string;
1477
1511
  export declare function toDate<T extends Date | number | string>(value?: T): (T & Date) | Date;
1478
1512
  export declare function toKebabCase(value: string): string;
1513
+ /**
1514
+ * Converts a string or number to a finite floating-point number.
1515
+ *
1516
+ * @example
1517
+ * toNumber("1 234,56") // 1234.56
1518
+ * toNumber("1,234.56") // 1234.56
1519
+ * toNumber("1,234") // 1.234
1520
+ */
1479
1521
  export declare function toNumber(value?: NumberOrString): number;
1480
1522
  export declare function toNumberByMax(value: string | number, max?: string | number, formatting?: boolean, language?: string): string | number;
1481
1523
  export declare function toNumberPositive(value?: number | string | null, defaultValue?: number): number;
@@ -1485,4 +1527,5 @@ export declare function toString<T>(value: T): string;
1485
1527
  export declare function transformation(value: any, isFunction?: boolean): any;
1486
1528
  export declare function uint8ArrayToBase64(bytes: Uint8Array): string;
1487
1529
  export declare function uniqueArray<T>(value: T[]): T[];
1488
- export declare function writeClipboardData(text: string): Promise<void>;
1530
+ export declare function writeClipboardData(text: string): Promise<void>;
1531
+ export declare const errorCauseList: ErrorCenterCauseList;
package/dist/library.js CHANGED
@@ -160,7 +160,7 @@ function oe(e, t, n) {
160
160
  return i.length === a.length ? i : (i.pop(), [...i, a.slice(n - 1).join(t)]);
161
161
  }
162
162
  //#endregion
163
- //#region \0@oxc-project+runtime@0.138.0/helpers/esm/typeof.js
163
+ //#region \0@oxc-project+runtime@0.139.0/helpers/esm/typeof.js
164
164
  function C(e) {
165
165
  "@babel/helpers - typeof";
166
166
  return C = typeof Symbol == "function" && typeof Symbol.iterator == "symbol" ? function(e) {
@@ -170,7 +170,7 @@ function C(e) {
170
170
  }, C(e);
171
171
  }
172
172
  //#endregion
173
- //#region \0@oxc-project+runtime@0.138.0/helpers/esm/toPrimitive.js
173
+ //#region \0@oxc-project+runtime@0.139.0/helpers/esm/toPrimitive.js
174
174
  function se(e, t) {
175
175
  if (C(e) != "object" || !e) return e;
176
176
  var n = e[Symbol.toPrimitive];
@@ -182,13 +182,13 @@ function se(e, t) {
182
182
  return (t === "string" ? String : Number)(e);
183
183
  }
184
184
  //#endregion
185
- //#region \0@oxc-project+runtime@0.138.0/helpers/esm/toPropertyKey.js
185
+ //#region \0@oxc-project+runtime@0.139.0/helpers/esm/toPropertyKey.js
186
186
  function ce(e) {
187
187
  var t = se(e, "string");
188
188
  return C(t) == "symbol" ? t : t + "";
189
189
  }
190
190
  //#endregion
191
- //#region \0@oxc-project+runtime@0.138.0/helpers/esm/defineProperty.js
191
+ //#region \0@oxc-project+runtime@0.139.0/helpers/esm/defineProperty.js
192
192
  function w(e, t, n) {
193
193
  return (t = ce(t)) in e ? Object.defineProperty(e, t, {
194
194
  value: n,
@@ -671,7 +671,7 @@ var ve = "ui-storage", ye = () => D.get("__ui:data-storage__", () => ({})), O =
671
671
  }
672
672
  get() {
673
673
  var e;
674
- return (e = this.storage.get()) == null ? !1 : e;
674
+ return (e = this.storage.get()) != null && e;
675
675
  }
676
676
  set(e) {
677
677
  this.storage.set(e);
@@ -1204,7 +1204,7 @@ var Me = class {
1204
1204
  return s() && !n ? !1 : !!t;
1205
1205
  }
1206
1206
  static isAge(e) {
1207
- return e ? e.age ? e.age * 1e3 + e.cacheAge >= Date.now() : !0 : !1;
1207
+ return e ? !e.age || e.age * 1e3 + e.cacheAge >= Date.now() : !1;
1208
1208
  }
1209
1209
  static isItem(e) {
1210
1210
  return e in this.getList();
@@ -4135,7 +4135,7 @@ var qt = class {
4135
4135
  }
4136
4136
  getReturnEverything() {
4137
4137
  var e;
4138
- return (e = this.getOptions().returnEverything) == null ? !1 : e;
4138
+ return (e = this.getOptions().returnEverything) != null && e;
4139
4139
  }
4140
4140
  getDelay() {
4141
4141
  var e;
@@ -4143,7 +4143,7 @@ var qt = class {
4143
4143
  }
4144
4144
  getFindExactMatch() {
4145
4145
  var e;
4146
- return (e = this.getOptions().findExactMatch) == null ? !1 : e;
4146
+ return (e = this.getOptions().findExactMatch) != null && e;
4147
4147
  }
4148
4148
  getClassName() {
4149
4149
  var e;
package/package.json CHANGED
@@ -1,7 +1,7 @@
1
1
  {
2
2
  "name": "@dxtmisha/functional-basic",
3
3
  "private": false,
4
- "version": "1.8.4",
4
+ "version": "1.8.5",
5
5
  "type": "module",
6
6
  "description": "Foundational isomorphic utility library for modern web and SSR development — HTTP client, state storage, i18n localization, SEO metadata, DOM events, formatting, and data utilities. Framework-agnostic, TypeScript-first.",
7
7
  "keywords": [
@@ -1,6 +0,0 @@
1
- # Coding Standards & Conventions
2
-
3
- - **Class Structure**: Properties/Variables (`public`->`protected`->`private`) -> Constructor -> Public Methods -> Protected Methods -> Private Methods. Within each method group, follow order: 1) `get` / `set` (getters/setters), 2) `is...` / `has...`, 3) `get...` / `set...`, 4) `add...` / `remove...`, 5) `update...` / `reset...`, 6) remaining methods. Within each subgroup, methods are grouped semantically by logical pairs and rules (e.g., `min` / `max`, `width` / `height`, `x` / `y` / `z`), and remaining methods are sorted alphabetically.
4
- - **Style/Types**: `PascalCase` classes, `camelCase` methods/props, `UPPER_SNAKE_CASE` constants. No `any` (use `unknown`/generics). Explicit return types for ALL methods. Export all interfaces. Type files: `*Types.ts`. Use `@effect/schema` for schemas.
5
- - **SSR Safety**: Isomorphic code. Do NOT store request state in globals. Use `isDomRuntime()` before `window`/`document`. Use `ServerStorage.get('key', () => new Class())` for request-isolated singletons.
6
- - **Utility & Primitive Functions**: ALWAYS use primitive helper functions from this package (e.g. `isFunction`, `executeFunction`, `isFilled`, `isObject`, `isString`, `isArray`, etc.) instead of writing custom inline checks or conditions.