tailwindcss-typography icon indicating copy to clipboard operation
tailwindcss-typography copied to clipboard

Do not underline links without an href.

Open eloyesp opened this issue 9 months ago • 0 comments

A link without the href attribute works like normal text, it would be nice to make prose just ignore those.

Changing the selector from:

.prose a {
  /* styles */
}

To:

.prose a[href] {
  /* styles */
}

Should be enough.

It seems that it is a single line change on: https://github.com/tailwindlabs/tailwindcss-typography/blob/39d20e194940903046f2e2733ce0a9b59ccd464b/src/styles.js#L1409

There are other rules that select "a", those can be changed too for consistency.

eloyesp avatar Jan 24 '25 16:01 eloyesp