New Case Study:See how Anthropic automated 95% of dependency reviews with Socket.Learn More
Socket
Sign inDemoInstall
Socket

async-ref

Package Overview
Dependencies
Maintainers
1
Versions
7
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

async-ref - npm Package Compare versions

Comparing version 0.1.2 to 0.1.3

2

dist/index.d.ts

@@ -12,3 +12,3 @@ declare type Notify = () => void;

set current(value: T);
then<TResult1 = T, TResult2 = never>(onfulfilled?: ((value: T) => TResult1 | PromiseLike<TResult1>) | undefined | null, onrejected?: ((reason: any) => TResult2 | PromiseLike<TResult2>) | undefined | null): PromiseLike<TResult1 | TResult2>;
then<TResult1 = T, TResult2 = never>(onfulfilled?: ((value: T) => TResult1 | PromiseLike<TResult1>) | undefined | null, onrejected?: ((reason: any) => TResult2 | PromiseLike<TResult2>) | undefined | null): Promise<TResult1 | TResult2>;
resolve(value: T): void;

@@ -15,0 +15,0 @@ reject(error: Error): void;

{
"name": "async-ref",
"description": "Async ref objects for React. A tiny bridge between React.useSyncExternalStore and React.Suspense.",
"version": "0.1.2",
"version": "0.1.3",
"main": "dist/index.js",

@@ -39,4 +39,4 @@ "module": "dist/index.mjs",

"build": "tsup",
"prepublishOnly": "jest && tsup"
"prepublishOnly": "jest && tsc && tsup"
}
}

@@ -48,3 +48,3 @@ type Notify = () => void;

/**
* The PendingValue resolved itself before the callback was invoked.
* The AsyncMutableRefObject resolved itself before the callback was invoked.
* So here we make sure to still resolve the promise.

@@ -94,3 +94,3 @@ */

onrejected?: ((reason: any) => TResult2 | PromiseLike<TResult2>) | undefined | null
): PromiseLike<TResult1 | TResult2> {
): Promise<TResult1 | TResult2> {
return this.#promise

@@ -97,0 +97,0 @@ .then(

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

SocketSocket SOC 2 Logo

Product

  • Package Alerts
  • Integrations
  • Docs
  • Pricing
  • FAQ
  • Roadmap
  • Changelog

Packages

npm

Stay in touch

Get open source security insights delivered straight into your inbox.


  • Terms
  • Privacy
  • Security

Made with ⚡️ by Socket Inc