You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
then the statement: const result = await confirm(message, options);
Shows error:
TS2345: Argument of type '{ render: (message: any, onConfirm: any, onCancel: any) => Element; }' is not assignable to parameter of type 'Options'.
The types returned by 'render(...)' are incompatible between these types.
Type 'Element' is missing the following properties from type 'Element': attributes, classList, className, clientHeight, and 123 more.
How can I fix it?
The text was updated successfully, but these errors were encountered:
const options = { render: (message, onConfirm, onCancel) => { return ( <> <h2> "Are you sure? </h2> <p>{message}</p> <PrimaryButton onClick={onConfirm} text="Yes" style={{ marginRight: '10px' }} /> <DefaultButton onClick={onCancel} text="No" style={{ marginLeft: '10px' }} /> </> ); } };
then the statement:
const result = await confirm(message, options);
Shows error:
How can I fix it?
The text was updated successfully, but these errors were encountered: