wawandco / milo

Milo is an HTML linter written in Go
MIT License
20 stars 0 forks source link

False Positive 0002:doctype/valid about XML declaration #37

Closed christianhujer closed 4 years ago

christianhujer commented 4 years ago

Given the following well-formed and valid HTML 5.2 file in XML Syntax (see https://www.w3.org/TR/2017/REC-html52-20171214/introduction.html#html-vs-xhtml):

<?xml version="1.0"?>
<!DOCTYPE html>
<html xmlns="http://www.w3.org/1999/xhtml" xml:lang="en">
<head>
    <title>Milo Test</title>
</head>
<body>
    <h1>Milo Test</h1>
</body>
</html>

When running milo review on this file, milo reports the following false positive:

test.xhtml:1:1: doctype tag must be valid (0002:doctype/valid)