/// import { handler, recipe, UI } from "commontools"; declare global { namespace JSX { interface IntrinsicElements { "ct-button": any; } } } interface State { count: number; } const existing = handler((_event, { state }: { state: State }) => { console.log(state.count); }); export default recipe("Existing", (state) => { return { [UI]: ( Existing ), }; });