watermark icon indicating copy to clipboard operation
watermark copied to clipboard

[React18] 设置了 `monitor={ture}` 之后,页面卡死

Open nnmax opened this issue 2 years ago • 0 comments

以前的Issues

#129 全局水印与其它遮罩层冲突

问题描述

  1. 升级为 React 18 后,页面会卡死。将 monitor 设置为 false 后正常;
  2. React 18 中的 React.FC 类型已经将 children 属性移除,希望在 WatermarkProps 中添加上 children,否则会报类型错误;

复现步骤

最小复现 Demo

环境详情

  • @pansy/watermark version: ^3.1.14
  • react version: ^18.2.0
  • react-dom version: ^18.2.0
  • typescript version: ^4.9.5

nnmax avatar Feb 20 '23 05:02 nnmax