Closed ejerskov closed 1 year ago
This was discussed previously in #329 and we decided not to make it configurable.
It is possible to implement your own getSelector
function and use that in place of the library one if you need to override this as the attribution model does include the full entry.
See also the discussion starting at https://github.com/GoogleChrome/web-vitals/pull/329#issuecomment-1457632304 where the previous requester realised that the selector is truncated to 100 based on right to left, rather than left to right so it will hopefully contain the more specific part of the selector even if it doesn't have the full selector.
It seems that the attribution debug_target is truncated after 100 characters.
Code from readme:
In our case (and I will assume in many others' as well) we have a DOM with with very deep css selectors and encoded by emotion causing them to be very long. When the selector gets truncated the debug_target is actually of no use since we cant find the correct element.