chore: backport retro compatible commits for the Docusaurus v2.1 release (#8033)

Co-authored-by: sebastienlorber <lorber.sebastien@gmail.com>
Co-authored-by: Joshua Chen <sidachen2003@gmail.com>
Co-authored-by: Sébastien Lorber <slorber@users.noreply.github.com>
Co-authored-by: whiteand <andrewbeletskiy@gmail.com>
Co-authored-by: yzhe819 <68207314+yzhe819@users.noreply.github.com>
Co-authored-by: Ngô Quốc Đạt <56961917+datlechin@users.noreply.github.com>
Co-authored-by: Kevin Østerkilde <kevin@oesterkilde.dk>
Co-authored-by: Bagdasar Ovsepyan <66012777+b-ovsepian@users.noreply.github.com>
Co-authored-by: Yoni Chechik <chechik.yoni@gmail.com>
Co-authored-by: adventure-yunfei <adventure.yunfei@gmail.com>
Co-authored-by: Morgane Dubus <30866152+mdubus@users.noreply.github.com>
This commit is contained in:
Sébastien Lorber 2022-09-02 12:20:33 +02:00 committed by GitHub
parent bb65b5c578
commit 26d2b9a018
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23
73 changed files with 764 additions and 250 deletions

View file

@ -86,7 +86,7 @@ export function getFileLoaderUtils(): FileLoaderUtils {
*/
images: () => ({
use: [loaders.url({folder: 'images'})],
test: /\.(?:ico|jpe?g|png|gif|webp)(?:\?.*)?$/i,
test: /\.(?:ico|jpe?g|png|gif|webp|avif)(?:\?.*)?$/i,
}),
fonts: () => ({
@ -100,7 +100,7 @@ export function getFileLoaderUtils(): FileLoaderUtils {
*/
media: () => ({
use: [loaders.url({folder: 'medias'})],
test: /\.(?:mp4|webm|ogv|wav|mp3|m4a|aac|oga|flac)$/i,
test: /\.(?:mp4|avi|mov|mkv|mpg|mpeg|vob|wmv|m4v|webm|ogv|wav|mp3|m4a|aac|oga|flac)$/i,
}),
svg: () => ({