UNPKG

glsl-pipeline

Version:

Prototype complex pipelines directly from a single shader by branching it into stages using React Three Fiber/React.

15 lines (14 loc) 579 B
import { ForwardRefExoticComponent, PropsWithoutRef, RefAttributes } from 'react'; /** * Allows using a TS v4 labeled tuple even with older typescript versions */ export type NamedArrayTuple<T extends (...args: any) => any> = Parameters<T>; /** * Utility type to declare the type of a `forwardRef` component so that the type is not "evaluated" in the declaration * file. */ export type ForwardRefComponent<P, T> = ForwardRefExoticComponent<PropsWithoutRef<P> & RefAttributes<T>>; /** * Similar to keyof in Typescript but with value */ export type ValueOf<T> = T[keyof T];