Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Fix image cache for vector and animated images (#20480)
Fixes: #19100 > According to https://nextjs.org/docs/basic-features/image-optimization#caching Next.js populates a cache dir when using the new <Image /> component. This is not the case when using SVG files. This results in a performance penalty. I created a function for writing images to cache directory (`wrirteToCacheDir`) and it is called for all images. However, vector and animated images are not optimized before writing them to cache dir Related to #18179
- Loading branch information
Showing
2 changed files
with
55 additions
and
6 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters