lxfater / inpaint-web

A free and open-source inpainting & image-upscaling tool powered by webgpu and wasm on the browser。| 基于 Webgpu 技术和 wasm 技术的免费开源 inpainting & image-upscaling 工具, 纯浏览器端实现。
https://inpaintweb.lxfater.com/
GNU General Public License v3.0
4.7k stars 523 forks source link

fix: use constant variable to replace react state varible to fix infi… #32

Closed libmw closed 7 months ago

libmw commented 7 months ago

Cause react setState won't change the state immediately,the old progress timmer state won't clear correctly,and the setGenerateProgress function will execute forever.It's no need to use state varible,all we need is a constant variable to save the progress interval timer. 微信截图_20231124180337 微信截图_20231124180232