import type React from "react"; interface ResultBlockProps { error?: string; result?: unknown; } const ResultBlock: React.FC = ({ error, result, }) => (
{error ?

Error: {error}

: null}
      {result !== undefined && result !== null 
        ? (typeof result === "object" ? JSON.stringify(result, null, 2) : String(result))
        : "No result"}
    
); export default ResultBlock;