Skip to content

Add option to prevent outputting unnecessary vertical whitespace #163

Closed
@mjbshaw

Description

@mjbshaw

Input:

<html>
<head>
<meta>
<meta>
<title>
TITLE
</title>
</head>
</html>

Output of ./tidy5 -access 1 --vertical-space f -wrap 0:

<!DOCTYPE html>
<html>
<head>
<meta>
<meta>
<title>TITLE</title>
</head>
<body>
</body>
</html>

This is a feature request to add an option to tell Tidy to not add newlines that aren't necessary. So the output would be more like the following:

<!DOCTYPE html>
<html><head><meta><meta><title>TITLE</title></head><body></body></html>

Right now, Tidy adds newlines that aren't actually needed. Ideally, an option would exist to make Tidy only add a newline if it was actually necessary (to preserve the original meaning of the document, or to fix existing issues in a document).

Metadata

Metadata

Assignees

No one assigned

    Type

    No type

    Projects

    No projects

    Milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions