OriginalSrc vs TransformedScr?

Anonymous
Not applicable
1629 0 0

Hi

I started working with GraphQl and I wanted to retrieve the originalSrc and transformedSrc images. As I understood if I make some changes on a image then the originalSrc will be kept and it will be not changed so that I can revert it if I like or did I misunderstand it?

I made some changes in my store on the image but originalSrc and transformedSrc were same

query getProductImage {
  product(id: "gid://shopify/Product/6041837600938") {
  	id
    title
    images(first:10) {
      edges {
       node {
         originalSrc
         transformedSrc
         id
       }
      }
    }  
  }
 
0 Likes
seop
New Member
2 0 0

To my understanding, the transformedSrc is used when you supply it with a desired width and/or height. 

I am planning on using it for thumbnails, where I would not want to download the full-resolution image, which will waste customer's time and data. You can input `maxWidth`, `maxHeight`, and `preferredContentType`.

0 Likes