Review 10.4 Merged

71926[BUGFIX] Do not HTML encode attributes in Script and Asset VH

Benni Mack CR +2 V +2 Normal +227 −1 updated 11/05/21, 11:54

Commit message

ScriptViewHelper and AssetViewHelper do not directly output any tag,
but only pass the arguments to AssetCollector.

Therefore the tag attribute values must not be HTML encoded.
To achieve that, we use a subclass of TagBuilder before the tag
is initialised, which does never encode attribute values.

The tag view helper inheritance is kept because the tag builder
nicely abstracts attribute handling, which otherwise would have to
be duplicated.

Also ensure that rendered children will not be encoded as this string
is used as CSS or JavaScript, where HTML encoding won't help or rather
break the code.

Review

  • Code review CR +2

    Imported before Forger kept the single votes, the next import adds them.

  • Verified V +2

    Imported before Forger kept the single votes, the next import adds them.

Issues 2

Files 4