Improve this Doc

Error: $compile:srcset
Invalid value passed to `attr.$set('srcset', value)`

Can't pass trusted values to `{0}`: "{1}"

Description

This error occurs if you try to programmatically set the srcset attribute with a non-string value.

This can be the case if you tried to avoid the automatic sanitization of the srcset value by passing a "trusted" value provided by calls to $sce.trustAsMediaUrl(value).

If you want to programmatically set explicitly trusted unsafe URLs, you should use $sce.trustAsHtml on the whole img tag and inject it into the DOM using the ng-bind-html directive.