Skip to content

SuperHTML complains about span > del and span > ins #127

@adiabatic

Description

@adiabatic

SuperHTML Version

0.6.2

Steps to Reproduce and Observed Behavior

Here's the HTML:

<!DOCTYPE html>
<html lang='en-US'>
	<head>
		<meta charset='UTF-8'>
		<title>span > del and span > ins complaints</title>
	</head>
	<body>
		<h1>
			<code>span > del</code>
			and <code>span > ins</code>
			complaints
		</h1>
		<p>I think <span><del>-</del><ins>+</ins>[NSString alloc]</span>
			is a fine method name.</p>
	</body>
</html>

superhtml doesn't like the del and ins where they are:

> superhtml check index.html
index.html:12:20: invalid nesting under <span>
   <p>I think <span><del>-</del><ins>+</ins>[NSString alloc]</span>
                     ^^^
index.html:12:32: invalid nesting under <span>
   <p>I think <span><del>-</del><ins>+</ins>[NSString alloc]</span>
                                 ^^^

Expected Output according to the HTML spec

I expect superhtml to not complain about this.

https://html.spec.whatwg.org/multipage/edits.html#the-del-element says that del can be used where phrasing content is expected.

Phrasing content has a long list of tags that count as phrasing content, and span is in the list.

Same thing for ins.

I don't think I'm misreading the spec.

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions