Stone.js API
    Preparing search index...

    Variable PageStatusConst

    PageStatus: <T extends Function = Function>(
        statusCode?: number,
        headers?: HeadersType,
    ) => MethodDecorator

    Decorator to set the status code of the response.

    Type Declaration

      • <T extends Function = Function>(
            statusCode?: number,
            headers?: HeadersType,
        ): MethodDecorator
      • Type Parameters

        • T extends Function = Function

        Parameters

        • OptionalstatusCode: number

          The status code of the response.

        • Optionalheaders: HeadersType

          The headers for the response.

        Returns MethodDecorator

        A method decorator.

    import { Page, PageStatus } from '@stone-js/use-react';

    @Page('/user-profile')
    class UserPage {
    @PageStatus()
    handle() {
    return { name: 'John Doe' };
    }
    }