react-native-image-viewer icon indicating copy to clipboard operation
react-native-image-viewer copied to clipboard

Cannot update during an existing state transition warning

Open Aryk opened this issue 3 years ago • 0 comments

I believe it's coming from here:

    // 保存 imageSize
    const saveImageSize = () => {
      // 如果已经 success 了,就不做处理
      if (this!.state!.imageSizes![index] && this!.state!.imageSizes![index].status !== 'loading') {
        return;
      }

      const imageSizes = this!.state!.imageSizes!.slice();
      imageSizes[index] = imageStatus;
      this.setState({ imageSizes });
    };

B93CCCEE-1E4B-44EC-8E56-4E9B46524C10

Aryk avatar Sep 28 '20 01:09 Aryk