applesauce-core 0.0.0-next-20250207162618 → 0.0.0-next-20250207172200

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.
@@ -22,4 +22,4 @@ export declare function getProfileContent(event: NostrEvent): ProfileContent;
22
22
  /** Checks if the content of the kind 0 event is valid JSON */
23
23
  export declare function isValidProfile(profile?: NostrEvent): boolean;
24
24
  /** Gets the display name from a profile with fallbacks */
25
- export declare function getDisplayName(metadata: ProfileContent): string | undefined;
25
+ export declare function getDisplayName(metadata?: ProfileContent): string | undefined;
@@ -1,2 +1,3 @@
1
1
  export * from "./get-observable-value.js";
2
2
  export * from "./share-latest-value.js";
3
+ export * from "./simple-timeout.js";
@@ -1,2 +1,3 @@
1
1
  export * from "./get-observable-value.js";
2
2
  export * from "./share-latest-value.js";
3
+ export * from "./simple-timeout.js";
@@ -0,0 +1,2 @@
1
+ import { MonoTypeOperatorFunction } from "rxjs";
2
+ export declare function simpleTimeout<T extends unknown>(first: number, message: string): MonoTypeOperatorFunction<T>;
@@ -0,0 +1,4 @@
1
+ import { throwError, timeout } from "rxjs";
2
+ export function simpleTimeout(first, message) {
3
+ return timeout({ first, with: () => throwError(() => new Error(message)) });
4
+ }
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "applesauce-core",
3
- "version": "0.0.0-next-20250207162618",
3
+ "version": "0.0.0-next-20250207172200",
4
4
  "description": "",
5
5
  "type": "module",
6
6
  "main": "dist/index.js",