镜像站点 · 本页由第三方 GitHub 只读镜像提供,非 GitHub 官方站点,不接受任何登录或凭据输入。前往 github.com
Skip to content

support itemscope as a boolean attribute #194

Closed

Description

@jvanasco

itemscope should be supported as a boolean attribute.

for reference, schema.org has been pushing it as such (https://schema.org/docs/gs.html#microdata_itemscope_itemtype)

running something through the Tokenizer/Sanitizer will set it to an empty attribute

input: <article itemscope>
output: <article itemscope="">

it looks like this can be handled by editing constants.py and doing the following to enable it on all tags:

booleanAttributes = {
-    "": frozenset(["irrelevant"]),
+    "": frozenset(["irrelevant", "itemscope"]),

Activity

  1. gsnedders commented on Jun 19, 2015

    @gsnedders
    Member

    Should probably just check the current list of boolean attributes in the spec, really. We're probably missing others too.

  2. modified the milestone: on Jun 6, 2016
  3. modified the milestones: , 1.0 on Oct 3, 2017
  4. added a commit that references this issue on Oct 31, 2017
  5. willkg commented on Nov 9, 2017

    @willkg
    Contributor

    I think this bug is fixed now, but if there are still outstanding things in this bug, please add a comment about what still needs to be done.

    Thank you for reporting!

  6. jvanasco commented on Nov 9, 2017

    @jvanasco
    ContributorAuthor

    thanks for finding/merging my old PR!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

      Milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions