Skip to content

Break line when encountering <div> tag #106

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Open
wants to merge 1 commit into
base: main
Choose a base branch
from

Conversation

SilverRainZ
Copy link

<div> is block-level element by default, let it behaves like a <p> element.


BTW, A block-level element always starts on a new line and ends on a new line, so the condition would be better to change from:

tag.eq_ignore_ascii_case(b"p") && is_tag_close

to:

tag.eq_ignore_ascii_case(b"p")

图片

I’m not sure if there was any special consideration for doing this before, so I kept the condition unchanged in this PR.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

1 participant