@flyo/nitro-astro 2.3.5 → 2.3.7

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -3,7 +3,10 @@ const { title, image, description, jsonld } = Astro.props;
3
3
  const jsonLdString = jsonld ? JSON.stringify(jsonld) : null;
4
4
 
5
5
  // Transform image to 1200x600 jpg for optimal social media display
6
- const transformedImage = `${image}/thumb/1200x600?format=jpg`
6
+ const transformedImage = `${image}/thumb/1200x630?format=jpg`
7
+ const transformedTwitterImage = `${image}/thumb/1200x600?format=jpg`
8
+
9
+ const ogUrl = Astro.url.href; // absolute URL
7
10
  ---
8
11
 
9
12
  {
@@ -29,10 +32,12 @@ const transformedImage = `${image}/thumb/1200x600?format=jpg`
29
32
  <>
30
33
  <meta name="image" content={transformedImage} />
31
34
  <meta property="og:image" content={transformedImage} />
32
- <meta name="twitter:image" content={transformedImage} />
35
+ <meta name="twitter:image" content={transformedTwitterImage} />
33
36
  </>
34
37
  )
35
38
  }
36
39
  {jsonLdString && <script type="application/ld+json" set:html={jsonLdString} />}
37
40
  <meta property="og:type" content="website" />
38
41
  <meta name="twitter:card" content="summary_large_image" />
42
+ <meta property="og:url" content={ogUrl} />
43
+ <link rel="canonical" href={ogUrl} />
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@flyo/nitro-astro",
3
- "version": "2.3.5",
3
+ "version": "2.3.7",
4
4
  "description": "Connecting Flyo Headless Content Hub into your Astro project.",
5
5
  "homepage": "https://dev.flyo.cloud/nitro",
6
6
  "keywords": [