Skip to content

fix(editor): include og:site_name in copied meta tags - #307

Merged
anurag629 merged 1 commit into
codercops:devfrom
prakashNalla:fix/meta-tags-site-name
Oct 28, 2026
Merged

anurag629 merged 1 commit into
codercops:devfrom
prakashNalla:fix/meta-tags-site-name

Conversation

@prakashNalla

Copy link
Copy Markdown
Contributor

Description

Copy Meta Tags left out og:site_name. generateMetaTags() already writes it when it gets a siteName, but ExportBar only passed the title, description and image URL. It now passes siteName from the editor params the same way as title and description, so it's there when Site Name is set and left out when it's empty.

Closes #306

How I Tested This

On npm run dev, /create/saas?template=saas-maintenance with the default Site Name ("Acme Cloud"), Copy Meta Tags now copies <meta property="og:site_name" content="Acme Cloud" /> next to og:title.

Added tests/editor/export-bar.test.ts, which renders ExportBar and checks what it passes to generateMetaTags(): siteName is there when Site Name is set and undefined when it's empty. The first test fails without the change and passes with it.

npm run check: 0 errors, 0 warnings. npm run test: 78 files, 1541 tests pass. agenda.test.ts timed out once at 5000ms ("renders valid SVG and PNG for 2, 3, and 4 sessions") in the full run and passes on its own. npm run build: passes.

AI Assistance

Claude helped me w/ understand the issue

Type of Change

  • Bug fix

Screenshots

N/A, nothing changes visually. The fix is in the copied text, which is shown above.

Checklist

  • This PR targets dev
  • I was assigned the linked issue
  • npm run check passes
  • npm run test passes
  • For a bug fix: the new test fails without my change
  • Tested locally with npm run dev
  • Screenshots included for visual changes
  • New templates follow the Template Guidelines

@anurag629 anurag629 left a comment

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

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

Thanks @prakashNalla, one line and a test, exactly right. Check (0 errors), all 1541 tests and the build pass on top of dev, and Copy Meta Tags now gets siteName the same way it gets the title and description.

@anurag629 anurag629 added the hacktoberfest-accepted PR counts for Hacktoberfest label Oct 28, 2026
@anurag629
anurag629 merged commit 0d4972c into codercops:dev Oct 28, 2026
3 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

hacktoberfest-accepted PR counts for Hacktoberfest

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Editor: Copy Meta Tags leaves out og:site_name even when Site Name is set

2 participants