JoshuaKGoldberg / create-typescript-app

Quickstart-friendly TypeScript template with comprehensive, configurable, opinionated tooling. 💝
MIT License
933 stars 69 forks source link

🚀 Feature: Lint for missing relative links in Markdown files #814

Open JoshuaKGoldberg opened 1 year ago

JoshuaKGoldberg commented 1 year ago

Bug Report Checklist

Overview

I just discovered the hard way that the README.md contains an incorrect path for a relative link 😱:

https://github.com/JoshuaKGoldberg/create-typescript-app/blob/30ea110a303193c783f50aa232e06bdca25ec04e/README.md#L48

(the file name is Migration.md, not Migrate.md)

That kind of typo should have been caught in CI. Surely there's some lint rule somewhere that could do this?

Additional Info

I did a quick Google and found https://github.com/theoludwig/markdownlint-rule-relative-links. Maybe that's usable?

If we end up switching to eslint-plugin-mdx or some such (#567), we'd want a lint rule from that config/plugin.

Paulie-Aditya commented 11 months ago

why don't we just change the docs to say ./docs/Migration.md ?

JoshuaKGoldberg commented 11 months ago

Not sure what you mean there. This issue is for adding tooling that will automatically find incorrect links, not about any specific incorrect link that exists today.