Skip to content
Draft
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion README.md
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@

It is built around a simple idea: SQL should be the source language for schema, migrations, queries, formatting, and diffing. TypeScript comes second. You should still get good generated types and wrappers, but without having to push the whole project through an ORM-shaped API.

**New to sqlfu?** Start with the [Getting Started](https://sqlfu.dev/docs/getting-started) walkthrough.
**New to sqlfu?** Start with the [Getting Started](https://sqlfu.dev/docs/getting-started) walkthrough, or read the [introductory blog post](https://sqlfu.dev/blog/introducing-sqlfu) for the thinking behind it.

![i know sqlfu](packages/sqlfu/docs/i-know-sqlfu.gif)

Expand Down
2 changes: 1 addition & 1 deletion packages/sqlfu/README.md
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@

It is built around a simple idea: SQL should be the source language for schema, migrations, queries, formatting, and diffing. TypeScript comes second. You should still get good generated types and wrappers, but without having to push the whole project through an ORM-shaped API.

**New to sqlfu?** Start with the [Getting Started](https://sqlfu.dev/docs/getting-started) walkthrough.
**New to sqlfu?** Start with the [Getting Started](https://sqlfu.dev/docs/getting-started) walkthrough, or read the [introductory blog post](https://sqlfu.dev/blog/introducing-sqlfu) for the thinking behind it.

![i know sqlfu](./docs/i-know-sqlfu.gif)

Expand Down
24 changes: 24 additions & 0 deletions tasks/link-intro-blog-post.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,24 @@
---
status: implemented
size: small
---

# Link to the introductory blog post from the homepage and README

> Status: implemented — both links in place, website build verified. Remaining: review.

The introductory blog post ([introducing sqlfu](https://sqlfu.dev/blog/introducing-sqlfu), `website/src/content/blog/introducing-sqlfu.md`) is the best "why does this exist" narrative we have, but nothing links to it from the two highest-traffic entry points: the landing page and the package README. Fix that.

- [x] Homepage (`website/src/pages/index.astro`): add a link to `/blog/introducing-sqlfu` in the hero area, as a low-key text link alongside/below the existing CTA buttons (`Start tutorial` / `Try in browser`). It should read like editorial copy ("read the introductory post"), not a third button competing with the CTAs. _Added a `hero-blog-link` paragraph under the `cta-row`, with a small muted style in `landing.css`._
- [x] README (`packages/sqlfu/README.md`): extend the existing "**New to sqlfu?**" line (or add an adjacent sentence) pointing to the blog post for the story/motivation, complementing the Getting Started link which covers the how-to. Root `README.md` regenerates from this via the pre-commit hook — don't edit it directly. _Extended the line 9 "New to sqlfu?" sentence; root README regenerated by the pre-commit hook._

## Assumptions (made on Misha's behalf)

- "The homepage" means the landing page hero, not the site nav. A nav `Blog` item linking to `/blog` may be worth doing too, but it's a different ask (blog index vs intro post) — left out of scope.
- Use the relative URL `/blog/introducing-sqlfu` on the website, and the absolute `https://sqlfu.dev/blog/introducing-sqlfu` in the README (read on GitHub/npm, so it needs the full URL).

## Implementation log

- Hero line copy: "Or read the introductory blog post for the thinking behind it." — placed directly after the CTA buttons inside `hero-main`.
- `.hero .hero-blog-link` selector (rather than bare `.hero-blog-link`) is needed to out-specify the existing `.hero p` rule that sets `color: var(--text)`.
- Verified with `pnpm build` in `website/`: Astro build passes and the link + style appear in `dist/index.html` and the bundled CSS. (The full build script later fails at `sync-ui.mjs` because `packages/ui/dist` wasn't built — pre-existing local-environment dependency, unrelated to this change.)
3 changes: 3 additions & 0 deletions website/src/pages/index.astro
Original file line number Diff line number Diff line change
Expand Up @@ -106,6 +106,9 @@ const demo = {
<a class="button primary" href="/docs/getting-started">Start tutorial</a>
<a class="button" href="/ui?demo=1">Try in browser</a>
</div>
<p class="hero-blog-link">
Or read the <a href="/blog/introducing-sqlfu">introductory blog post</a> for the thinking behind it.
</p>
</article>
</section>

Expand Down
6 changes: 6 additions & 0 deletions website/src/styles/landing.css
Original file line number Diff line number Diff line change
Expand Up @@ -249,6 +249,12 @@ a {
margin-top: 1.5rem;
}

.hero .hero-blog-link {
margin-top: 0.9rem;
font-size: 0.95rem;
color: var(--muted);
}

.button {
display: inline-flex;
align-items: center;
Expand Down
Loading