Computer >> Computer tutorials >  >> Programming >> Javascript

What is the most efficient way of assigning all my HTML5 video sources as trusted without having to loop over all of them


Add some config to assign trust to your videos in HTML5:

app.config(function($sceDelegateProvider) {
   $sceDelegateProvider.resourceUrlWhitelist([

   // allowing same origin resource loads
   'self',

   // allowing loading from our assets domain
   'https://media.w3.org/**']);
});