diff --git a/src/withSmartScroll.tsx b/src/withSmartScroll.tsx index 6715b33..c1d77e5 100644 --- a/src/withSmartScroll.tsx +++ b/src/withSmartScroll.tsx @@ -2,10 +2,10 @@ import React from 'react'; import SmartScrollView from './Provider'; import { Provider } from 'jotai'; -export const withSmartScroll = (child: () => React.ReactElement) => { - return () => ( +export const withSmartScroll = (child: (props?: any) => React.ReactElement) => { + return (props?: any) => ( - {child()} + {child(props)} ); };