I am in the process of developing a unique RxJS filter operator that requires a destructured array as a parameter.
Unfortunately, TypeScript seems to be throwing an error related to the type declaration:
Error TS2493: Tuple type '[]' with a length of '0' does not have an element at index '0'.
export function createCustomOperator<T extends []>() {
return pipe(
filter<T>(([param1, param2, param3])=> {
//add your logic here
})
);
}