Skip to content

iOS 에서 썸네일 저장시 이미지 반영 안됨 #108

Answered by da-in
da-in asked this question in Bugs
Discussion options

You must be logged in to vote

관련 이슈들입니다. 근본적인 해결법이라 우회적인 방식으로, 좋지 못합니다.
모두가 html-to-canvas 를 사용하는 것을 근본적인 해결책이라 말합니다 ㅋㅋㅋㅋㅋ😆

일단 아래 구현으로 적용해두되, 추후 리팩토링에서 html-to-canvas를 사용하면 좋을 것 같습니다.

toPng(previewRef.current).then(() => {
   if (previewRef.current) {
      toPng(previewRef.current).then(() => {
         if (previewRef.current) {
            toPng(previewRef.current).then((dataUrl) => {
               download(dataUrl, 'thumbnail.png');
            });
         }
      });
   }
});

html-to-image
bubkoo/html-to-image#52

dom-to-image
tsayen/dom-to-image#343

Replies: 3 comments

Comment options

You must be logged in to vote
0 replies
Comment options

da-in
Mar 3, 2023
Maintainer Author

You must be logged in to vote
0 replies
Comment options

da-in
Mar 3, 2023
Maintainer Author

You must be logged in to vote
0 replies
Answer selected by da-in
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Category
Bugs
Labels
bug Something isn't working
2 participants