adarshaacharya / portfolio-v2

Second iteration of my personal website v2.0 & blog build with @gatsbyjs. Please check https://github.com/adarshaacharya.com.np for new site.
MIT License
14 stars 43 forks source link

Image transformation gives 404 Error #61

Open nehakumarisaa opened 3 years ago

nehakumarisaa commented 3 years ago

Hi Adarsh,

Well described implementation. Helped me setup a similar thing I was trying for my website. Unfortunately, I am running into 404 error when I try to upload the transformed URL while the original one works perfectly. Did you come across a similar issue during your implementation?

I made sure that the folder structure is fine and the template names are right.

Thanks, Neha

github-actions[bot] commented 3 years ago

Thank you for submitting the issue. This automated message, author of this repo will reply you back soon.' first issue

adarshaacharya commented 3 years ago

transformed URL

Hi @nehakumarisaa I'm sorry I didn't get you what feature are you talking about ?

nehakumarisaa commented 3 years ago

So, I followed the implementation outlined by you in your blog 'https://adarshaacharya.com.np/blog/auto-generate-social-cards'

  1. Created Social Card for the blog post
  2. Called the getShareImage method within my script tag. - This returned the proper transformed image from cloudinary
  3. The next step was to add this returned value to my Head tag. - This is where I'm running into issue. The url isn't getting mapped to twitter:image at run time.

I'm using Jekyll template. So, I'm thinking this has got to do something with that. Would the Helmet Implementation work with Jekyll as well?

adarshaacharya commented 3 years ago

@nehakumarisaa Got it. I don't think above implementation will work Jekyll. Because as I mentioned in the blog the Helmet plugin I'm using is for Gatsby/React specifically. So, I don't think that will work for Jekyll.

May be there are other ways to inject into <head> tag in Jekyll?