🎩 You're Invited:Meet the Socket team at Black Hat in Las Vegas, August 3-6.RSVP
Sign In

@standardserver/shared

Package Overview
Dependencies
Maintainers
1
Versions
42
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

@standardserver/shared - npm Package Compare versions

Comparing version
0.0.15
to
0.0.16
+25
README.md
# @standardserver/shared
<div align="center">
<a href="https://codecov.io/gh/middleapi/standardserver">
<img alt="codecov" src="https://codecov.io/gh/middleapi/standardserver/branch/main/graph/badge.svg">
</a>
<a href="https://www.npmjs.com/package/@standardserver/shared">
<img alt="weekly downloads" src="https://img.shields.io/npm/dw/%40standardserver%2Fshared?logo=npm" />
</a>
<a href="https://github.com/middleapi/standardserver/blob/main/LICENSE">
<img alt="MIT License" src="https://img.shields.io/github/license/middleapi/standardserver?logo=open-source-initiative" />
</a>
<a href="https://discord.gg/TXEbwRBvQn">
<img alt="Discord" src="https://img.shields.io/discord/1308966753044398161?color=7389D8&label&logo=discord&logoColor=ffffff" />
</a>
<a href="https://deepwiki.com/middleapi/standardserver">
<img src="https://deepwiki.com/badge.svg" alt="Ask DeepWiki">
</a>
</div>
This package contains shared types and utilities for the `@standardserver` ecosystem. It has no runtime dependencies and can be used in any JavaScript environment.
## Learn more
For the higher-level project overview, see the root [Standard Server README](../../README.md).
+1
-13
declare function toArray<T>(value: T): T extends readonly any[] ? T : (T extends undefined | null ? never : T[]);
declare const PACKAGE_NAME = "@standardserver/shared";
declare const PACKAGE_VERSION = "0.0.15";
/**
* Generates a unique symbol for the specified name within the package scope.
* The symbol is globally registered using `Symbol.for` to ensure consistency across modules.
*
* @remarks
* - Ensure names are unique to avoid symbol collisions within the package.
* - Ensure package versions are synchronized (e.g., when the core package is updated, this package should also be updated).
*/
declare function getPackageSymbol(name: string): symbol;
/**
* Error thrown when an operation is aborted.

@@ -136,3 +124,3 @@ * Uses the standardized 'AbortError' name for consistency with JavaScript APIs.

export { AbortError, AsyncIteratorClass, PACKAGE_NAME, PACKAGE_VERSION, Queue, SequentialIdGenerator, emitUnhandledRejection, getOrBind, getPackageSymbol, isAsyncIteratorObject, isTypescriptObject, omit, parseEmptyableJSON, sequential, sleep, stringifyJSON, toArray, tryDecodeURIComponent };
export { AbortError, AsyncIteratorClass, Queue, SequentialIdGenerator, emitUnhandledRejection, getOrBind, isAsyncIteratorObject, isTypescriptObject, omit, parseEmptyableJSON, sequential, sleep, stringifyJSON, toArray, tryDecodeURIComponent };
export type { AsyncCleanupFn, AsyncIteratorClassNextFn, GetOrBindOptions, SleepOptions };
declare function toArray<T>(value: T): T extends readonly any[] ? T : (T extends undefined | null ? never : T[]);
declare const PACKAGE_NAME = "@standardserver/shared";
declare const PACKAGE_VERSION = "0.0.15";
/**
* Generates a unique symbol for the specified name within the package scope.
* The symbol is globally registered using `Symbol.for` to ensure consistency across modules.
*
* @remarks
* - Ensure names are unique to avoid symbol collisions within the package.
* - Ensure package versions are synchronized (e.g., when the core package is updated, this package should also be updated).
*/
declare function getPackageSymbol(name: string): symbol;
/**
* Error thrown when an operation is aborted.

@@ -136,3 +124,3 @@ * Uses the standardized 'AbortError' name for consistency with JavaScript APIs.

export { AbortError, AsyncIteratorClass, PACKAGE_NAME, PACKAGE_VERSION, Queue, SequentialIdGenerator, emitUnhandledRejection, getOrBind, getPackageSymbol, isAsyncIteratorObject, isTypescriptObject, omit, parseEmptyableJSON, sequential, sleep, stringifyJSON, toArray, tryDecodeURIComponent };
export { AbortError, AsyncIteratorClass, Queue, SequentialIdGenerator, emitUnhandledRejection, getOrBind, isAsyncIteratorObject, isTypescriptObject, omit, parseEmptyableJSON, sequential, sleep, stringifyJSON, toArray, tryDecodeURIComponent };
export type { AsyncCleanupFn, AsyncIteratorClassNextFn, GetOrBindOptions, SleepOptions };

@@ -5,8 +5,2 @@ function toArray(value) {

const PACKAGE_NAME = "@standardserver/shared";
const PACKAGE_VERSION = "0.0.15";
function getPackageSymbol(name) {
return Symbol.for(`${PACKAGE_NAME}@${PACKAGE_VERSION}/${name}`);
}
class AbortError extends Error {

@@ -244,2 +238,2 @@ constructor(...rest) {

export { AbortError, AsyncIteratorClass, PACKAGE_NAME, PACKAGE_VERSION, Queue, SequentialIdGenerator, emitUnhandledRejection, getOrBind, getPackageSymbol, isAsyncIteratorObject, isTypescriptObject, omit, parseEmptyableJSON, sequential, sleep, stringifyJSON, toArray, tryDecodeURIComponent };
export { AbortError, AsyncIteratorClass, Queue, SequentialIdGenerator, emitUnhandledRejection, getOrBind, isAsyncIteratorObject, isTypescriptObject, omit, parseEmptyableJSON, sequential, sleep, stringifyJSON, toArray, tryDecodeURIComponent };
{
"name": "@standardserver/shared",
"type": "module",
"version": "0.0.15",
"version": "0.0.16",
"license": "MIT",

@@ -14,2 +14,3 @@ "homepage": "https://standardserver.dev",

"exports": {
"./package.json": "./package.json",
".": {

@@ -16,0 +17,0 @@ "types": "./dist/index.d.mts",