user image

Mohamed Atef
Published in : 2021-12-08

Could not be processed as an image because it has an invalid content type

React js

Facebook debugger is returning this error and not displaying the preview image “could not be processed as an image because it has an invalid content type”, anyone knows about this error however the og:image content leads to the correct preview image & I added og:image:width & og:image:height, 
any suggestions, please? (Reactjs application)
the screenshot attached below 

— After many times of trying i figured out the issue ---
I did 2 steps until the image appear in the preview

  1. Reduces the dimensions & size of the attached image  
  2. Change the format of the image form PNG to JPEG & included .jpg in the URL in meta content instead of .jpeg
<meta property="og:image" content="/static/screenshot.jpg" />
<meta property="og:image:width" content="1200"/>
<meta property="og:image:height" content="630"/>

Thank you for your support

 

web-brackets.com

Comments

There is no comments yet

Leave a comment

Join us

Join our community and get the chance to solve your code issues & share your opinion with us

Sign up Now

Related posts

React Component displaying a list of lines
Publish date: 2022-03-19 | Comments: 3

Tag: React js

TypeError: Super expression must either be null or a function
Publish date: 2022-03-13 | Comments: 2

Tag: React js

Best way to update the state in one class component from the redux store?
Publish date: 2022-03-30 | Comments: 3

Tag: React js

useStyles Invalid hook call class component
Publish date: 2022-02-10 | Comments: 2

Tag: React js