Quote:
Originally Posted by Turtle91
Perhaps adjusting the heuristics of the plugin to check <span>s for corresponding css...if found=don't delete... would be better?? Otherwise, for consistency, you could also delete all empty <em> tags... 
|
strong and em tags have intrinsic formatting, which is what they are usually used for.
They always do something.
And I've never seen the point of them anyway -- you should be using b and i, they're shorter.
If you want to style them so they work differently, well, you can do some pretty crazy stuff with CSS, and mostly ignore what tags are "supposed to" do.
But span is a no-op. It has no structural meaning, and no fundamental styling quirks.
All it does is redefines an arbitrary chunk of characters (allowing you to slap a label on it), unlike every other tag.
Redefining the default nature of a tag is something to be done with deliberation.
So why ask for trouble?
...
The reason I suggested matching on "small" wasn't because there is a tag like that. It's because if you are going to use a span, use a span class="small"
Classes rule. "but <span> is 20% shorter" is an
excuse.
You can probably get away with it, though. Just pointing out that when you say "but it's shorter" you are quite obviously valuing short and quick over meticulous devotion to correctness.
One place where you won't get away with it, is when anyone tries applying heuristics to your work.
And the appropriate response is not "breathe down the neck of anyone who ever writes a heuristic to make sure it knows about all the crazy things @Turtle91 (or ____) might do".
Down that road lies madness.
Of course, additional checks might be a useful feature, but depending on them?