core
npmShared primitives used across all Angular Helpers packages β platform detection, Transferable helpers, and Worker pooling.
TypeScriptmain.ts
import { injectPlatform, injectWorkerPool, isTransferable } from '@angular-helpers/core';
// No provider setup required β all utilities are standalone inject() functions.
// pnpm add @angular-helpers/coreπ₯οΈ Platform
βοΈ Workers & Transferables
isTransferable
Pure predicate that returns `true` if a value is a `Transferable` instance that can be moved zero-copy via `postMessage`. Guards every Transferable type with a `typeof` check so it is safe in Web Workers, Node.js, and SSR contexts where some globals may be absent.
Explore APIβ
WorkerPool / injectWorkerPool
Manages a pool of Web Workers with round-robin job dispatch. `injectWorkerPool` is the DI-aware factory that automatically terminates all workers when the injection context is destroyed. Used internally by `@angular-helpers/security` to run ReDoS-safe regex operations off the main thread.
Explore APIβ