This repository has been archived on 2026-05-03. You can view files and clone it. You cannot open issues or pull requests or push a commit.
Files
novarix-networks-homepage/node_modules/next/dist/client/components/unrecognized-action-error.d.ts
T
Kismet Hasanaj 34dc9aec52 .
2026-05-02 20:07:02 +02:00

23 lines
790 B
TypeScript

export declare class UnrecognizedActionError extends Error {
constructor(...args: ConstructorParameters<typeof Error>);
}
/**
* Check whether a server action call failed because the server action was not recognized by the server.
* This can happen if the client and the server are not from the same deployment.
*
* Example usage:
* ```ts
* try {
* await myServerAction();
* } catch (err) {
* if (unstable_isUnrecognizedActionError(err)) {
* // The client is from a different deployment than the server.
* // Reloading the page will fix this mismatch.
* window.alert("Please refresh the page and try again");
* return;
* }
* }
* ```
* */
export declare function unstable_isUnrecognizedActionError(error: unknown): error is UnrecognizedActionError;