Skip to content

docs(installation): badge the "Choose your release line" picker table#62

Merged
jlc488 merged 2 commits into
mainfrom
feat/maven-central-badges-in-docs
May 23, 2026
Merged

docs(installation): badge the "Choose your release line" picker table#62
jlc488 merged 2 commits into
mainfrom
feat/maven-central-badges-in-docs

Conversation

@jlc488

@jlc488 jlc488 commented May 23, 2026

Copy link
Copy Markdown
Contributor

Summary

The picker table at the top of the installation page showed the coordinate-with-version string twice (e.g. `kr.devslab:easy-paging-spring-boot-starter:4.0.0`) and needed a manual edit on every release. Replaced with shields.io Maven Central badges per row — same pattern just landed on:

What changed

Before After
Column header "Use" / "좌표" "Latest on Maven Central" / "Maven Central 최신"
SB4 row's version cell `kr.devslab:easy-paging-spring-boot-starter:4.0.0` Badge with `?versionPrefix=4`
SB3 row's version cell `kr.devslab:easy-paging-spring-boot-starter:3.0.0` Badge with `?versionPrefix=3`
Below the table "The rest of this page covers..." + nudge: "Copy-paste snippets are in Adding the dependency below"

What did NOT change (intentional)

Every copy-paste snippet on the page stays as text with a hardcoded version:

  • "Adding the dependency" tabs (Gradle Kotlin/Groovy, Maven)
  • "Optional — reactive companion artifact" snippet
  • "Need a different MyBatis line?" snippet
  • "Staying on Spring Boot 3.3–3.5?" snippet at the bottom

Same for `docs/index.md`'s Quick install block — it's a copy-paste target. The link from there back to the installation page surfaces the badged picker for the "what's current?" question.

Why two layers (badge + text)

  • Badge answers "what version is actually current?" (auto-updates, never stale)
  • Snippet answers "what do I paste into my build file?" (stable, copy-friendly)
  • When the snippet's hardcoded version visually mismatches the badge, that's the signal to bump the snippet. Honest staleness, not silent drift.

Why `versionPrefix` per row

Without the filter, the SB3 maintenance row's badge would jump to the latest `4.x` patch the moment one ships — hiding the maintenance line's actual state. `versionPrefix=3` and `versionPrefix=4` keep the two lines independent.

Test plan

jlc488 added 2 commits May 23, 2026 23:02
The picker table at the top of the installation page showed the
coordinate string twice (artifact ID + hardcoded version, e.g.
`kr.devslab:easy-paging-spring-boot-starter:4.0.0`). That meant the
table needed a manual edit on every patch release — and was the same
class of slip that PR #6 / #4 (on the org `.github` profile) and
PR #59 (on devslab-examples) just fixed for their version-display
surfaces.

Replaced the "Use" / "좌표" column with a shields.io Maven Central
badge per row, using:
  - versionPrefix=4 for the SB4 active line — `4.x.y`
  - versionPrefix=3 for the SB3 maintenance line — `3.x.y`

The badges read the latest version directly from Maven Central, so
the next patch (4.0.1, 3.0.1, etc.) shows up here without a doc edit.

Column header renamed "Use" → "Latest on Maven Central" / "좌표" →
"Maven Central 최신" to be honest about the new semantic (the cell is
display, not copy-paste).

Added a one-line nudge below the table pointing readers at the
"Adding the dependency" section for actual copy-paste snippets.

NOT changed (intentional, all copy-paste targets):
  - "Adding the dependency" tabs (Gradle Kotlin/Groovy, Maven)
  - "Optional — reactive companion artifact" snippet
  - "Need a different MyBatis line?" snippet
  - "Staying on Spring Boot 3.3–3.5?" snippet at the bottom

A reader who wants to know "what's actually current" reads the badge.
A reader who wants to paste the dep into their build file reads the
snippet. The two layers don't fight — the snippet's hardcoded version
will visually mismatch the badge when it drifts, which is the signal
to bump the snippet.

index.md Quick install snippet kept as-is for the same reason — it's
a copy-paste target. The link from index.md → installation.md surfaces
the badged picker table for the "what's current?" question.

Follow-up if drift becomes a problem: a CI mismatch check that fails
the PR when a snippet's version disagrees with the corresponding
badge's source-of-truth (Maven Central latest).
…adges

Matches the simplification just applied to devslab-examples#59.

Before:  ![Maven Central](...?label=kr.devslab%3A<art>&versionPrefix=N)
         (long label squeezes version text)
After:   ![Maven Central](...?versionPrefix=N)
         (short default label, version is readable)

The artifact ID is redundant — the picker table's left column already
names the line (`4.x.y` / `3.x.y`) and clicking the badge still lands
on the Maven Central artifact page with the full coordinate visible.
@jlc488
jlc488 merged commit 4b90612 into main May 23, 2026
5 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.

1 participant