James
Explore posts from serversCDCloudflare Developers
•Created by James on 11/4/2023 in #workers-help
SSR for injecting social meta tags
You will probably be better off making something custom that resembles the page rather than just tossing in the page itself
18 replies
CDCloudflare Developers
•Created by James on 11/4/2023 in #workers-help
SSR for injecting social meta tags
You could try.
workers-og
takes in a string rather than JSX. You might have some trouble with it formatting correctly to fit the bounds of the image, as well as what it's compatible with (e.g styling and elements on the page that may not be supported by the render engine backing the library).18 replies
CDCloudflare Developers
•Created by James on 11/4/2023 in #workers-help
SSR for injecting social meta tags
@bacon I ended up going a pretty backwards route since I had an existing worker that did the image generation using https://github.com/kvnang/workers-og. So the role of the pages function ended up just being injecting the meta tags which I figured out how to do using the source code of
@cloudflare/pages-plugin-vercel-og
18 replies
CDCloudflare Developers
•Created by James on 11/4/2023 in #workers-help
SSR for injecting social meta tags
@bacon
18 replies
CDCloudflare Developers
•Created by James on 11/4/2023 in #workers-help
SSR for injecting social meta tags
And is it installed in your package.json?
18 replies
CDCloudflare Developers
•Created by James on 11/4/2023 in #workers-help
SSR for injecting social meta tags
I'd imagine that's a problem with https://developers.cloudflare.com/workers/runtime-apis/nodejs/
18 replies
CDCloudflare Developers
•Created by James on 11/4/2023 in #workers-help
SSR for injecting social meta tags
For anyone that finds this, I found https://developers.cloudflare.com/pages/platform/functions/plugins/vercel-og/ which will fit my use case!
18 replies