Open stephenmathieson opened 4 months ago
@stephenmathieson Thanks for the suggestion. That's definitely a problem we should find a solution to. I'm not sure whether it should be a separate option. Axe-core truncates HTML snippets to prevent this problem. I think what we might want to do also put limits on attributes, both on the length of an attribute value, and of the number of attributes.
I'll bring this up with the team to come up with a solution.
Talked about this, we agree this should happen. Will be in 4.11 / 5.0, won't do this in a patch.
We think the best way to do this is to:
Product
axe-core
Feature Description
When analyzing a axe Watcher results in prod, we noticed we have a few excessively large datums (>1MB). This is preventing us from migrating result data to a different (much faster data store).
After digging further, it was noticed that this is due to axe-core including the element in violation's
outerHTML
(eg.violations[x].nodes[y].html
) and its related node'souterHTML
(.violations[x].nodes[y].relatedNodes[z].html
). Consider the following snippet:It appears axe-core is already truncating some parts (children) of the element's HTML, but not the element itself.
An option similar to
axe.configure({ noHtml: true })
which causes axe-core to truncate ALL HTML snippets would be extremely helpful.