October 25, 2024
Chicago 12, Melborne City, USA
CSS

Canvas Aspect Ratio for Instagram Story – Html2Canvas


I have a project written with React. In this project, the user can share the current screen as a story on instagram. here I first convert the html screen to canvas and then to image and share it that way.

The problem here starts in the part of converting the screen to canvas. I want the size of the generated image to be suitable for instagram. here I want to produce canvas in accordance with the 9 / 16 ratio. if I can crop the image I produce from the top and bottom, there will be no problem, but I don’t know how to do it.

Example Image; this image’s aspect-ratio is : 215:466

example image



You need to sign in to view this answers

Leave feedback about this

  • Quality
  • Price
  • Service

PROS

+
Add Field

CONS

+
Add Field
Choose Image
Choose Video