Skip to content

Fix Multiple Images

Latest
Compare
Choose a tag to compare
@theianjones theianjones released this 06 Mar 16:08

Bug Fix

When you added an image to an mdx post, the placeholder svg would still render even though the image loaded.

Adding gatsby-remark-images to the gatsby-mdx-plugin was the solution.

{
     resolve: `gatsby-plugin-mdx`,
     options: {
       extensions: ['.mdx', '.md', '.markdown'],
       gatsbyRemarkPlugins: [
         {
           resolve: 'gatsby-remark-images',
           options: {
             backgroundColor: '#fafafa',
             maxWidth: 1035,
           },
         },
       ],
     },
   },

Thanks @Creeland.