import Intro from '/docs/snippets/breaking-change-page-intro.md'
import MigrationIntro from '/docs/snippets/breaking-change-page-migration-intro.md'
The isSupportedImage method is removed#
The isSupportedImage method has been issuing a deprecation warning ever since v4, and is finally being removed in Strapi 5.
Breaking change description#
In Strapi v4
The isSupportedImage method is supported, but deprecated.
In Strapi 5
The isSupportedImage method is removed.
Developers must use either isImage to check if a file is an image, or isOptimizableImage to check if the file is an image that can be optimized.
Manual migration#
Replace occurences of the isSupportedImage method in your code by the appropriate method, isImage or isOptimizableImage, depending on your needs. Note that the behavior in Strapi v4 was equivalent to isOptimizableImage.