Skip to content
module@warp-drive/react

Interface ChromeComponentProps<RT> ​

ts
interface ChromeComponentProps<RT> {
  children: ReactNode;
  features: ContentFeatures<RT>;
  state: RequestState | null;
}

Defined in: -private/request.tsx:57

The props passed to the component given as the chrome prop of `<Request />`.

Example ​

tsx
import type { ChromeComponentProps } from "@warp-drive/react";

function Chrome({ children, features }: ChromeComponentProps<unknown>) {
  return <div className={features.isRefreshing ? "is-refreshing" : ""}>{children}</div>;
}

Type Parameters ​

RT ​

RT

Properties ​

children ​

ts
children: ReactNode;

Defined in: -private/request.tsx:61

Whichever state component <Request /> is rendering.


features ​

ts
features: ContentFeatures<RT>;

Defined in: -private/request.tsx:69

The ContentFeatures used to refresh, reload, or abort the request.


state ​

ts
state: RequestState | null;

Defined in: -private/request.tsx:65

The RequestState of the request, or null while idle.

Released under the MIT License.