Skip to content

docs: fix sponsor block markup and add header badges - #369

Open
SurefireStudios wants to merge 1 commit into
PatrickJS:mainfrom
SurefireStudios:docs/readme-header-and-sponsor-markup
Open

SurefireStudios wants to merge 1 commit into
PatrickJS:mainfrom
SurefireStudios:docs/readme-header-and-sponsor-markup

Conversation

@SurefireStudios

@SurefireStudios SurefireStudios commented Sep 10, 2026

Copy link
Copy Markdown

+13 / -14, confined to the header. All 223 list entries are untouched — I verified by diffing the entry set and URL set before and after.

I read scripts/check-awesome-list.mjs and scripts/check-repo-hygiene.mjs first and kept the changes inside what they allow. Both pass locally, and awesome-lint@2.3.0 reports no new findings.

The sponsorship block is invalid HTML

Each entry opens an anchor inside a heading, then closes the heading first:

<h3><a href="...">coderabbit.ai - Cut Code Review Time & Bugs in Half. Instantly.</h3>
  <a href="...">
    <img alt="CodeRabbit.ai Sponsorship Logo" src="./cr_logo.png" width=350>
  </a>

Three problems:

  1. The first <a> is never closed. The </h3> lands inside an open anchor.
  2. Block-level <h3> elements sit inside a <p>, which the HTML parser implicitly closes at the first <h3> — so the centering wrapper stops applying partway through.
  3. width=350 is unquoted.

It renders acceptably today only because GitHub's sanitiser recovers from it. That recovery isn't a guarantee, and the same markup behaves differently outside GitHub (npm, mirrors, README aggregators).

Each sponsor is now a properly closed anchor inside its heading, wrapped in a <div> instead of a <p>, with quoted attributes and the trailing whitespace after the Unblocked heading removed. Sponsor names, taglines, links and UTM parameters are byte-identical.

The Unblocked logo loads from a fork

src="https://github.com/claire-gong-18/awesome-cursorrules/blob/main/Unblocked-logo-sq-words-over-gradient-1024w.png?raw=true"

Unblocked-logo-sq-words-over-gradient-1024w.png is already committed to this repository, but the README pulls it from a fork instead. If that fork is deleted, renamed, or made private, a paying sponsor's logo silently 404s. Now points at the local file, consistent with how cr_logo.png is referenced.

I left the Warp logo on user-attachments — that's GitHub's own CDN, not a third-party repo.

Badges

A row under the title for stars, forks, contributing and license.

The contributing badge links contributing.md, which the README does not reference anywhere. check-awesome-list.mjs forbids a Contributing entry in the Contents section, and the README rightly has no License section — a badge satisfies discoverability without touching either rule.

What I deliberately did not change

Reading the check scripts saved me from several changes that looked like improvements but are prohibited by design:

  • No License section. check-awesome-list.mjs:72 explicitly forbids one.
  • No Contributing or Footnotes entries in Contents. Forbidden at line 61.
  • Sponsorships stays an HTML <h2>. Converting it to ## would make it the first markdown h2 and break the "Contents must be the first top-level section" rule.
  • No rule counts in the Contents links. checkContentsHierarchy matches the link exactly and would reject anything appended.
  • Rule links left absolute. Enforced by checkRuleLinks, and scripts/convert-readme-links.mjs exists for it.

Two things noticed, not addressed here

43 rule files in rules/ are not listed in the README — including python.mdc, react.mdc, go.mdc, rust.mdc, docker.mdc, fastapi.mdc and clean-code.mdc. Some look like deliberate short-slug duplicates of listed rules, so this needs curation judgement rather than a bulk edit. Happy to open a separate PR if you tell me which should be listed. (No broken links in the other direction — all 214 linked rules exist.)

scripts/check-readme-hygiene.mjs and check-rule-hygiene.mjs crash on Windows. They build a path via new URL(...).pathname, which yields /C:/... and resolves to C:\C:\...:

Error: Cannot find module 'C:\C:\Users\...\scripts\check-repo-hygiene.mjs'

fileURLToPath() would fix it. Doesn't affect CI on Linux, but it blocks Windows contributors from running the checks locally. Separate PR if wanted.

Summary by CodeRabbit

  • Documentation
    • Added repository status badges for stars, forks, contributions, and licensing.
    • Updated sponsorship presentation with improved alignment, image sizing, and a local logo asset.

The sponsorship block had invalid HTML. Each entry opened an anchor inside a
heading but closed the heading first:

    <h3><a href="...">coderabbit.ai - ...</h3>
      <a href="...">
        <img ...>
      </a>

The first <a> is never closed, the </h3> lands inside it, and block-level
headings sit inside a <p>, which browsers implicitly close at the first <h3>.
Rendering depends on sanitiser recovery rather than the markup itself. Each
sponsor is now a closed anchor inside its heading, inside a <div> rather
than a <p>, with quoted width attributes and no trailing whitespace.

The Unblocked logo was also loaded from a third-party fork:

    https://github.com/claire-gong-18/awesome-cursorrules/blob/main/...?raw=true

Unblocked-logo-sq-words-over-gradient-1024w.png is already committed here, so
the image now resolves locally. A sponsor logo should not depend on a fork
that this repository does not control.

Adds a badge row under the title for stars, forks, contributing and license.
The contributing badge links contributing.md, which the README did not
reference anywhere; check-awesome-list forbids Contributing in the Contents
section, and a badge stays outside that section.

Sponsorships stays as an HTML <h2> so Contents remains the first markdown
h2, as check-awesome-list requires. All 223 list entries are untouched.

Verified with scripts/check-awesome-list.mjs and
scripts/check-repo-hygiene.mjs --only readme, both passing.
Copilot AI lite review requested due to automatic review settings September 10, 2026 16:58

Copilot AI left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

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

Copilot was unable to review this pull request because the user who requested the review has reached their quota limit.

@coderabbitai

coderabbitai Bot commented Sep 10, 2026

Copy link
Copy Markdown
Contributor

Review Change StackReview Change Stack

No actionable comments were generated in the recent review. 🎉

ℹ️ Recent review info
⚙️ Run configuration

Configuration used: defaults

Review profile: CHILL

Plan: Advanced

Run ID: c552fac2-79d4-4f94-a145-af15560cec5a

📥 Commits

Reviewing files that changed from the base of the PR and between b044f95 and f1c03c4.

📒 Files selected for processing (1)
  • README.md

Included review availability: Your plan provides up to 10 included reviews per hour; 9 remain after this review.


📝 Walkthrough

Walkthrough

The README adds GitHub repository badges and updates sponsorship markup with centered alignment, escaped ampersands, explicit image widths, and a local logo asset.

Changes

README presentation updates

Layer / File(s) Summary
Badges and sponsorship markup
README.md
The README adds stars, forks, contributions, and license badges. Sponsorship markup uses centered alignment, escaped ampersands, explicit image dimensions, and a local Unblocked logo path.

Estimated code review effort: 1 (Trivial) | ~2 minutes

Merge Risk: ⚪ Minimal · up to f1c03

This README-only change adds badges and repairs sponsor markup while preserving the list content; no concrete merge-blocking risk is identified.

🚥 Pre-merge checks | ✅ 5
✅ Passed checks (5 passed)
Check name Status Explanation
Title check ✅ Passed The title is concise and accurately identifies the two main changes: fixing sponsorship markup and adding README header badges.
Description check ✅ Passed The description is detailed and directly covers the changes, affected file, validation results, preserved content, and additional maintainer notes. It does not use the required template headings or ex…
Docstring Coverage ✅ Passed No functions found in the changed files to evaluate docstring coverage. Skipping docstring coverage check. Docstring coverage is scoped to functions touched by this diff. Analyzed 0 functions across 0…
Linked Issues check ✅ Passed Check skipped because no linked issues were found for this pull request.
Out of Scope Changes check ✅ Passed Check skipped because no linked issues were found for this pull request.
✨ Finishing Touches
🧪 Generate unit tests (beta)
  • Create PR with unit tests

Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out.

❤️ Share

Comment @coderabbitai help to get the list of available commands.

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.

2 participants