# @types/knockout-postbox

> TypeScript definitions for knockout-postbox

Latest version **0.0.5** (published 2023-11-07) · MIT license · 0 weekly downloads

## Install

```sh
npm install @types/knockout-postbox
pnpm add @types/knockout-postbox
yarn add @types/knockout-postbox
bun add @types/knockout-postbox
```

## Health

**Score 40/100 (D)** — status: abandoned.

Positive: has types; no vulnerabilities; popular repo; extremely popular.

Warnings: low downloads; no esm support; pre 1.0.

Negative: abandoned.

## Facts

| | |
|---|---|
| Version | 0.0.5 |
| Published | 2023-11-07 |
| First published | 2018-02-14 |
| Weekly downloads | 0 |
| License | MIT |
| TypeScript types | bundled |
| Module format | CommonJS |
| Dependencies | 1 |
| Unpacked size | 6.3 KB |
| Known vulnerabilities | 0 |
| Install scripts | no |
| GitHub stars | 51420 |
| Maintainers | types |

## Links

- npm: https://www.npmjs.com/package/@types/knockout-postbox
- Repository: https://github.com/DefinitelyTyped/DefinitelyTyped
- Homepage: https://github.com/DefinitelyTyped/DefinitelyTyped/tree/master/types/knockout-postbox
- npm.io page: https://npm.io/package/@types/knockout-postbox

## Dependencies (1)

- [@types/knockout](https://npm.io/package/@types/knockout.md) *

## Recent versions

- 0.0.5 (latest) — 2023-11-07
- 0.0.2 (ts3.0) — 2020-05-15
- 0.0.0 (ts2.3) — 2018-02-14
- 0.0.4 — 2023-10-18
- 0.0.3 — 2023-09-14
- 0.0.1 — 2020-05-15

## README

# Installation
> `npm install --save @types/knockout-postbox`

# Summary
This package contains type definitions for knockout-postbox (https://github.com/rniemeyer/knockout-postbox).

# Details
Files were exported from https://github.com/DefinitelyTyped/DefinitelyTyped/tree/master/types/knockout-postbox.
## [index.d.ts](https://github.com/DefinitelyTyped/DefinitelyTyped/tree/master/types/knockout-postbox/index.d.ts)
````ts
/// <reference types="knockout" />

interface KnockoutPostBox {
    subscribe<T>(topic: string, handler: (value: T) => void, target?: any): KnockoutSubscription;
    publish<T>(topic: string, value?: T): void;
    defaultComparer<T>(newValue: T, oldValue: T): boolean;
    serializer: (object: any) => string;
    reset(): void;
}

interface KnockoutObservable<T> {
    subscribeTo(
        topic: string,
        useLastPublishedValueToInitialize?: boolean,
        transform?: (val: any) => T,
    ): KnockoutObservable<T>;
    unsubscribeFrom(topic: string): KnockoutObservable<T>;
    publishOn(
        topic: string,
        skipInitialPublish?: boolean,
        equalityComparer?: (newValue: T, oldValue: T) => boolean,
    ): KnockoutObservable<T>;
    stopPublishingOn(topic: string): KnockoutObservable<T>;
    syncWith(
        topic: string,
        initializeWithLatestValue?: boolean,
        skipInitialPublish?: boolean,
        equalityComparer?: (newValue: T, oldValue: T) => boolean,
    ): KnockoutObservable<T>;
}

interface KnockoutObservableArray<T> {
    subscribeTo(
        topic: string,
        useLastPublishedValueToInitialize?: boolean,
        transform?: (val: any) => any, /* T */
    ): KnockoutObservableArray<T>;
    unsubscribeFrom(topic: string): KnockoutObservableArray<T>;
    publishOn(
        topic: string,
        skipInitialPublish?: boolean,
        equalityComparer?: (newValue: any, /* T */ oldValue: any /* T */) => boolean,
    ): KnockoutObservableArray<T>;
    stopPublishingOn(topic: string): KnockoutObservableArray<T>;
    syncWith(
        topic: string,
        initializeWithLatestValue?: boolean,
        skipInitialPublish?: boolean,
        equalityComparer?: (newValue: any, /* T */ oldValue: any /* T */) => boolean,
    ): KnockoutObservableArray<T>;
}

interface KnockoutStatic {
    postbox: KnockoutPostBox;
}

````

### Additional Details
 * Last updated: Tue, 07 Nov 2023 09:09:38 GMT
 * Dependencies: [@types/knockout](https://npmjs.com/package/@types/knockout)

# Credits
These definitions were written by [Judah Gabriel Himango](https://debuggerdotbreak.wordpress.com).

---
_Source: https://npm.io/package/@types/knockout-postbox · Machine-readable twin of the npm.io package page. Health data is recomputed on every publish._
