Skip to content

Related blog component #3768

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Merged
merged 23 commits into from
May 23, 2025
Merged

Conversation

Blargian
Copy link
Member

@Blargian Blargian commented May 7, 2025

Summary

Adds a related blog component which uses the keywords on each page to search for related blog posts.

Overview:

  • adds src/components/RelatedBlogs which queries Algolia blogs index and displays the results
  • adds RelatedBlogs to src/theme/DocItem/Layout/index.js such that it shows at the bottom of each page. If a page specifies show_related_blogs: true
  • adds keywords to many pages as they return better results than the fallback method detailed below.

Notes:

  • The component searches on keywords, title, description
  • Only "Engineering" blogs currently (we should add product too though imo)
  • Anything from 2023-01-01 (I know we said 18 months but we have good content on joins earlier than 18 months)

To do:

  • Be able to specify docs directories from docusaurus.config.js so that it's not necessary to add show_related_blogs to each page individually (eg. we would want to exclude all reference docs).
  • Mobile styling + further styling tweaks
  • Only index blogs less than 18 months old

Checklist

@Blargian Blargian requested review from a team as code owners May 7, 2025 18:48
@Blargian Blargian requested a review from laeg May 7, 2025 18:48
Copy link

vercel bot commented May 7, 2025

@Blargian is attempting to deploy a commit to the ClickHouse Team on Vercel.

A member of the Team first needs to authorize it.

@Blargian Blargian linked an issue May 7, 2025 that may be closed by this pull request
@Blargian Blargian removed the request for review from laeg May 7, 2025 20:09
Copy link

vercel bot commented May 7, 2025

The latest updates on your projects. Learn more about Vercel for Git ↗︎

Name Status Preview Comments Updated (UTC)
clickhouse-docs ✅ Ready (Inspect) Visit Preview May 23, 2025 1:32pm
2 Skipped Deployments
Name Status Preview Comments Updated (UTC)
clickhouse-docs-ru ⬜️ Ignored (Inspect) Visit Preview May 23, 2025 1:32pm
clickhouse-docs-zh ⬜️ Ignored (Inspect) Visit Preview May 23, 2025 1:32pm

@@ -0,0 +1,3180 @@
{
Copy link
Collaborator

@gingerwizard gingerwizard May 13, 2025

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

lets not checkin

Copy link
Collaborator

@gingerwizard gingerwizard left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

  1. Lets default to false and replace the existing related blog posts which are static - if a page has current related, we'll show
  2. Move the keywords to the CMS and extract with Algolia

@Blargian
Copy link
Member Author

@gingerwizard have made the following changes:

  • don't show by default, only enabled if show_related_blogs: true is set
  • Keywords added to CMS for Engineering blogs
  • I am showing anything from 2023-01-01 as we get better results for JOINs specifically. Tom has some great blogs on those.

Can always be better, but relevancy is substantially better now I think.

@gingerwizard
Copy link
Collaborator

@Blargian can we remove any existing related content recommendations. If you search for Related Content you will find some

@Blargian Blargian merged commit 5119c9d into ClickHouse:main May 23, 2025
12 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Related blogs component
2 participants