From 4398649ebe45be5fca19a5ebc0f1c4df6980c4bc Mon Sep 17 00:00:00 2001 From: "Zed A. Shaw" Date: Sun, 4 Jun 2023 17:47:58 -0400 Subject: [PATCH] Fixing up the microcode in SEOTricks.svelte and then adding it to blog content. --- client/components/SEOTricks.svelte | 14 ++++++------- .../templates/rendered/pages/index.svelte | 21 ++++++++++++++++++- rendered/pages/blog/[slug]/index.svelte | 4 ++-- rendered/pages/blog/index.svelte | 19 +++++++++++++++-- 4 files changed, 46 insertions(+), 12 deletions(-) diff --git a/client/components/SEOTricks.svelte b/client/components/SEOTricks.svelte index b1545ef..a0317d1 100644 --- a/client/components/SEOTricks.svelte +++ b/client/components/SEOTricks.svelte @@ -38,13 +38,6 @@ - -
- {#each Object.keys(schema_data) as key} - - {/each} -
- {#each Object.keys(og) as key} @@ -58,3 +51,10 @@
+ + +
+ {#each Object.keys(schema_data) as key} + + {/each} +
diff --git a/commands/templates/rendered/pages/index.svelte b/commands/templates/rendered/pages/index.svelte index 16cfa85..80219d2 100644 --- a/commands/templates/rendered/pages/index.svelte +++ b/commands/templates/rendered/pages/index.svelte @@ -2,6 +2,7 @@ import Layout from '../Layout.svelte'; import IconImage from '$/client/components/IconImage.svelte'; import { developer_admin } from "$/lib/api.js"; + import SEOTricks from "$/client/components/SEOTricks.svelte"; const components = [ {title: "Accordion", icon: "align-justify"}, @@ -42,8 +43,26 @@ {title: "WTVideo", icon: "video"}, ]; + import { og_base_host, twitter_user } from "$/client/config.js"; + + let og = { + "title": "Bandolier Template", // title of the article + "description": "The example project that is used in the course Learn JavaScript the Hard Way.", // description for inside preview + "url": og_base_host, // URL to article + "type": "website", // not mentioned on linked in but needed + } + + let twitter = { + "card": "summary", // must be summary, summary_large_image, app, player + "creator": twitter_user, // @username of content creator + "description": og.description, // max 200 chars + "site": "@lzsthw", // @username of site + "title": og.title, + } + +